Commit da956b3 1 parent fef7118 commit da956b3 Copy full SHA for da956b3
File tree 3 files changed +6
-4
lines changed
3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -18,3 +18,4 @@ data/conf.php
18
18
src /import /*
19
19
.gitignore
20
20
.dockerignore
21
+ src /inc /conf.php
Original file line number Diff line number Diff line change 15
15
}
16
16
17
17
// if a pepper is set from an older version, we have to save it to the new file location
18
- if (isset ($ PEPPER ) && !file_exists ($ DIRECTORIES ['config ' ] . "/pepper .json " )) {
19
- file_put_contents ($ DIRECTORIES ['config ' ] . "/pepper .json " , json_encode ($ PEPPER ));
18
+ if (isset ($ PEPPER ) && !file_exists ($ DIRECTORIES ['config ' ] . "/config .json " )) {
19
+ file_put_contents ($ DIRECTORIES ['config ' ] . "/config .json " , json_encode (array ( ' PEPPER ' => $ PEPPER ) ));
20
20
}
21
21
} else {
22
22
// read env variables (when running with docker-compose)
45
45
}
46
46
47
47
// load data
48
- $ PEPPER = json_decode (file_get_contents ($ DIRECTORIES ['config ' ] . "/pepper.json " ));
48
+ $ CONFIG = json_decode (file_get_contents ($ DIRECTORIES ['config ' ] . "/config.json " ), true );
49
+ $ PEPPER = $ CONFIG ['PEPPER ' ];
49
50
}
Original file line number Diff line number Diff line change 87
87
Util::randomString (32 ),
88
88
Util::randomString (32 )
89
89
];
90
- file_put_contents ($ DIRECTORIES ['config ' ] . "/pepper .json " , json_encode ($ PEPPER ));
90
+ file_put_contents ($ DIRECTORIES ['config ' ] . "/config .json " , json_encode (array ( ' PEPPER ' => $ PEPPER ) ));
91
91
}
92
92
93
93
// save version and build
You can’t perform that action at this time.
0 commit comments