Skip to content

Commit

Permalink
MDL-23068 removing obsolete $result and removing empty upgrade files …
Browse files Browse the repository at this point in the history
…that would be probably never used at all + minor cleanup/fixing
  • Loading branch information
skodak committed Jul 4, 2010
1 parent 77dd303 commit a4cdd6d
Show file tree
Hide file tree
Showing 73 changed files with 842 additions and 2,166 deletions.
8 changes: 4 additions & 4 deletions admin/xmldb/actions/XMLDBAction.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -239,22 +239,22 @@ function upgrade_savepoint_php($structure) {
case 'lib': /// has own savepoint function
$result = XMLDB_LINEFEED .
' /// Main savepoint reached' . XMLDB_LINEFEED .
' upgrade_main_savepoint($result, XXXXXXXXXX);' . XMLDB_LINEFEED;
' upgrade_main_savepoint(true, XXXXXXXXXX);' . XMLDB_LINEFEED;
break;
case 'mod': /// has own savepoint function
$result = XMLDB_LINEFEED .
' /// ' . $pluginname . ' savepoint reached' . XMLDB_LINEFEED .
' upgrade_mod_savepoint($result, XXXXXXXXXX, ' . "'$pluginname'" . ');' . XMLDB_LINEFEED;
' upgrade_mod_savepoint(true, XXXXXXXXXX, ' . "'$pluginname'" . ');' . XMLDB_LINEFEED;
break;
case 'block': /// has own savepoint function
$result = XMLDB_LINEFEED .
' /// ' . $pluginname . ' savepoint reached' . XMLDB_LINEFEED .
' upgrade_block_savepoint($result, XXXXXXXXXX, ' . "'$pluginname'" . ');' . XMLDB_LINEFEED;
' upgrade_block_savepoint(true, XXXXXXXXXX, ' . "'$pluginname'" . ');' . XMLDB_LINEFEED;
break;
default: /// rest of plugins
$result = XMLDB_LINEFEED .
' /// ' . $pluginname . ' savepoint reached' . XMLDB_LINEFEED .
' upgrade_plugin_savepoint($result, XXXXXXXXXX, ' . "'$plugintype'" . ', ' . "'$pluginname'" . ');' . XMLDB_LINEFEED;
' upgrade_plugin_savepoint(true, XXXXXXXXXX, ' . "'$plugintype'" . ', ' . "'$pluginname'" . ');' . XMLDB_LINEFEED;
}
return $result;
}
Expand Down
41 changes: 0 additions & 41 deletions blocks/activity_modules/db/upgrade.php

This file was deleted.

41 changes: 0 additions & 41 deletions blocks/calendar_month/db/upgrade.php

This file was deleted.

41 changes: 0 additions & 41 deletions blocks/calendar_upcoming/db/upgrade.php

This file was deleted.

7 changes: 3 additions & 4 deletions blocks/community/db/upgrade.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,8 @@ function xmldb_block_community_upgrade($oldversion) {
global $CFG, $DB;

$dbman = $DB->get_manager();
$result = true;

if ($result && $oldversion < 2010042701) {
if ($oldversion < 2010042701) {

/// Define table block_community to be created
$table = new xmldb_table('block_community');
Expand All @@ -71,9 +70,9 @@ function xmldb_block_community_upgrade($oldversion) {
}

/// community savepoint reached
upgrade_block_savepoint($result, 2010042701, 'community');
upgrade_block_savepoint(true, 2010042701, 'community');
}


return $result;
return true;
}
41 changes: 0 additions & 41 deletions blocks/course_list/db/upgrade.php

This file was deleted.

41 changes: 0 additions & 41 deletions blocks/course_summary/db/upgrade.php

This file was deleted.

41 changes: 0 additions & 41 deletions blocks/news_items/db/upgrade.php

This file was deleted.

41 changes: 0 additions & 41 deletions blocks/online_users/db/upgrade.php

This file was deleted.

41 changes: 0 additions & 41 deletions blocks/participants/db/upgrade.php

This file was deleted.

Loading

0 comments on commit a4cdd6d

Please sign in to comment.