1
0
Fork 0
mirror of https://github.com/sbrl/Pepperminty-Wiki.git synced 2024-11-22 16:33:00 +00:00

Switch over another stray path in the core to the new system

This commit is contained in:
Starbeamrainbowlabs 2015-11-12 10:01:21 +00:00
parent 414eb58850
commit 9c1b5faf28
4 changed files with 11 additions and 11 deletions

View file

@ -540,11 +540,11 @@ function get_subpages($pageindex, $pagename)
*/ */
function check_subpage_parents($pagename) function check_subpage_parents($pagename)
{ {
global $pageindex; global $pageindex, $paths;
// Save the new pageindex and return if there aren't any more parent pages to check // Save the new pageindex and return if there aren't any more parent pages to check
if(strpos($pagename, "/") === false) if(strpos($pagename, "/") === false)
{ {
file_put_contents("./pageindex.json", json_encode($pageindex, JSON_PRETTY_PRINT)); file_put_contents($paths->pageindex, json_encode($pageindex, JSON_PRETTY_PRINT));
return; return;
} }

View file

@ -202,11 +202,11 @@ function get_subpages($pageindex, $pagename)
*/ */
function check_subpage_parents($pagename) function check_subpage_parents($pagename)
{ {
global $pageindex; global $pageindex, $paths;
// Save the new pageindex and return if there aren't any more parent pages to check // Save the new pageindex and return if there aren't any more parent pages to check
if(strpos($pagename, "/") === false) if(strpos($pagename, "/") === false)
{ {
file_put_contents("./pageindex.json", json_encode($pageindex, JSON_PRETTY_PRINT)); file_put_contents($paths->pageindex, json_encode($pageindex, JSON_PRETTY_PRINT));
return; return;
} }

View file

@ -14,7 +14,7 @@
"author": "Starbeamrainbowlabs", "author": "Starbeamrainbowlabs",
"description": "Exposes Pepperminty Wiki's new page protection mechanism and makes the protect button in the 'More...' menu on the top bar work.", "description": "Exposes Pepperminty Wiki's new page protection mechanism and makes the protect button in the 'More...' menu on the top bar work.",
"id": "action-protect", "id": "action-protect",
"lastupdate": 1447322278, "lastupdate": 1447322382,
"optional": false "optional": false
}, },
{ {