Commit 80ad18bd authored by Robert Lyon's avatar Robert Lyon
Browse files

Bug 1581262: allow 'root' user to make default portfoilo page



When upgrading from old 15.04 to new 16.10 site

behatnotneeded

Change-Id: I737f481338778aeac9d865575a96029e9e044277
Signed-off-by: default avatarRobert Lyon <robertl@catalyst.net.nz>
parent a253ba9c
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -4179,7 +4179,11 @@ function xmldb_core_upgrade($oldversion=0) {
        // Add a site default portfolio page template
        log_debug('Add a site default portfolio page template');
        require_once('view.php');
        // Need to make sure 'root' user has admin privs for this task
        // and then make sure it doesn't afterwards
        update_record('usr', array('admin' => 1), array('id' => 0));
        install_system_portfolio_view();
        update_record('usr', array('admin' => 0), array('id' => 0));
    }

    if ($oldversion < 2015091700) {