Skip to content

Commit

Permalink
Merge branch 'MDL-28250-24' of git://github.com/danpoltawski/moodle i…
Browse files Browse the repository at this point in the history
…nto MOODLE_24_STABLE
  • Loading branch information
Damyon Wiese committed May 17, 2013
2 parents 0571a68 + 8fec03b commit a1972f5
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 3 deletions.
21 changes: 21 additions & 0 deletions lib/db/upgrade.php
Expand Up @@ -1719,5 +1719,26 @@ function xmldb_main_upgrade($oldversion) {
upgrade_main_savepoint(true, 2012120303.09);
}

if ($oldversion < 2012120304.01) {
// Fix incorrect cc-nc url. Unfortunately the license 'plugins' do
// not give a mechanism to do this.

$sql = "UPDATE {license}
SET source = :url, version = :newversion
WHERE shortname = :shortname AND version = :oldversion";

$params = array(
'url' => 'http://creativecommons.org/licenses/by-nc/3.0/',
'shortname' => 'cc-nc',
'newversion' => '2013051500',
'oldversion' => '2010033100'
);

$DB->execute($sql, $params);

// Main savepoint reached.
upgrade_main_savepoint(true, 2012120304.01);
}

return true;
}
4 changes: 2 additions & 2 deletions lib/licenselib.php
Expand Up @@ -192,9 +192,9 @@ static public function install_licenses() {

$license->shortname = 'cc-nc';
$license->fullname = 'Creative Commons - No Commercial';
$license->source = 'http://creativecommons.org/licenses/by-nd/3.0/';
$license->source = 'http://creativecommons.org/licenses/by-nc/3.0/';
$license->enabled = 1;
$license->version = '2010033100';
$license->version = '2013051500';
$active_licenses[] = $license->shortname;
self::add($license);

Expand Down
2 changes: 1 addition & 1 deletion version.php
Expand Up @@ -30,7 +30,7 @@
defined('MOODLE_INTERNAL') || die();


$version = 2012120304.00; // 20121203 = branching date YYYYMMDD - do not modify!
$version = 2012120304.01; // 20121203 = branching date YYYYMMDD - do not modify!
// RR = release increments - 00 in DEV branches
// .XX = incremental changes

Expand Down

0 comments on commit a1972f5

Please sign in to comment.