Browse Source

Use array() instead of shorthand as done in the other scripts

Tobias Reich 8 years ago
parent
commit
a5c47cf022
1 changed files with 7 additions and 7 deletions
  1. 7 7
      php/database/update_030102.php

+ 7 - 7
php/database/update_030102.php

@@ -8,37 +8,37 @@ use Lychee\Modules\Database;
 use Lychee\Modules\Response;
 
 // Change type of the album id field
-$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `album` `album` BIGINT UNSIGNED NOT NULL", [LYCHEE_TABLE_PHOTOS]);
+$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `album` `album` BIGINT UNSIGNED NOT NULL", array(LYCHEE_TABLE_PHOTOS));
 $result = Database::execute($connection, $query, 'update_030102', __LINE__);
 if ($result===false) Response::error('Could not change type of the album id field!');
 
 // Add index to the album id field
-$query  = Database::prepare($connection, "ALTER TABLE `?` ADD INDEX `Index_album` (`album`)", [LYCHEE_TABLE_PHOTOS]);
+$query  = Database::prepare($connection, "ALTER TABLE `?` ADD INDEX `Index_album` (`album`)", array(LYCHEE_TABLE_PHOTOS));
 $result = Database::execute($connection, $query, 'update_030102', __LINE__);
 if ($result===false) Response::error('Could not add index to the album id field!');
 
 // Add index to the star field
-$query  = Database::prepare($connection, "ALTER TABLE `?` ADD INDEX `Index_star` (`star`)", [LYCHEE_TABLE_PHOTOS]);
+$query  = Database::prepare($connection, "ALTER TABLE `?` ADD INDEX `Index_star` (`star`)", array(LYCHEE_TABLE_PHOTOS));
 $result = Database::execute($connection, $query, 'update_030102', __LINE__);
 if ($result===false) Response::error('Could not add index to the star field!');
 
 // Change type of the checksum field
-$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `checksum` `checksum` CHAR(40) NULL DEFAULT NULL", [LYCHEE_TABLE_PHOTOS]);
+$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `checksum` `checksum` CHAR(40) NULL DEFAULT NULL", array(LYCHEE_TABLE_PHOTOS));
 $result = Database::execute($connection, $query, 'update_030102', __LINE__);
 if ($result===false) Response::error('Could not change type of the checksum field!');
 
 // Change type of the thumbUrl field
-$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `thumbUrl` `thumbUrl` CHAR(37) NOT NULL", [LYCHEE_TABLE_PHOTOS]);
+$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `thumbUrl` `thumbUrl` CHAR(37) NOT NULL", array(LYCHEE_TABLE_PHOTOS));
 $result = Database::execute($connection, $query, 'update_030102', __LINE__);
 if ($result===false) Response::error('Could not change type of the thumbUrl field!');
 
 // Change type of the id field
-$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `id` `id` BIGINT(14) UNSIGNED NOT NULL", [LYCHEE_TABLE_PHOTOS]);
+$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `id` `id` BIGINT(14) UNSIGNED NOT NULL", array(LYCHEE_TABLE_PHOTOS));
 $result = Database::execute($connection, $query, 'update_030102', __LINE__);
 if ($result===false) Response::error('Could not change type of the id field!');
 
 // Change type of the id field
-$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `id` `id` BIGINT(14) UNSIGNED NOT NULL", [LYCHEE_TABLE_ALBUMS]);
+$query  = Database::prepare($connection, "ALTER TABLE `?` CHANGE `id` `id` BIGINT(14) UNSIGNED NOT NULL", array(LYCHEE_TABLE_ALBUMS));
 $result = Database::execute($connection, $query, 'update_030102', __LINE__);
 if ($result===false) Response::error('Could not change type of the id field!');