From c61946329cb7b17ef4a6971d304dcb8f8957c1d2 Mon Sep 17 00:00:00 2001
From: Marc Alexander <admin@m-a-styles.de>
Date: Sun, 15 Mar 2020 12:50:39 +0100
Subject: [PATCH] [ticket/14754] Refactor migration for 3.3 and use ULINT

PHPBB3-14754
---
 .../v33x/add_email_notifications_table.php    | 42 +++++++++----------
 1 file changed, 20 insertions(+), 22 deletions(-)

diff --git a/phpBB/phpbb/db/migration/data/v33x/add_email_notifications_table.php b/phpBB/phpbb/db/migration/data/v33x/add_email_notifications_table.php
index 46a9e45f67..0ad172f5c0 100644
--- a/phpBB/phpbb/db/migration/data/v33x/add_email_notifications_table.php
+++ b/phpBB/phpbb/db/migration/data/v33x/add_email_notifications_table.php
@@ -11,40 +11,38 @@
  *
  */
 
-namespace phpbb\db\migration\data\v32x;
+namespace phpbb\db\migration\data\v33x;
 
 class add_email_notifications_table extends \phpbb\db\migration\migration
 {
 	static public function depends_on()
 	{
-		return array(
-			'\phpbb\db\migration\data\v32x\v323',
-		);
+		return [
+			'\phpbb\db\migration\data\v330\v330',
+		];
 	}
 
 	public function update_schema()
 	{
-		return array(
-			'add_tables'	=> array(
-				$this->table_prefix . 'email_notifications' => array(
-					'COLUMNS'	=> array(
-						'notification_type_id'	=> array('USINT', 0),
-						'item_id'				=> array('UINT', 0),
-						'item_parent_id'		=> array('UINT', 0),
-						'user_id'				=> array('UINT', 0),
-					),
-					'PRIMARY_KEY' => array('notification_type_id', 'item_id', 'item_parent_id', 'user_id'),
-				),
-			),
-		);
+		return [
+			'add_tables'	=> [
+				$this->table_prefix . 'email_notifications' => [
+					'COLUMNS'	=> [
+						'notification_type_id'	=> ['USINT', 0],
+						'item_id'				=> ['ULINT', 0],
+						'item_parent_id'		=> ['ULINT', 0],
+						'user_id'				=> ['ULINT', 0],
+					],
+					'PRIMARY_KEY' => ['notification_type_id', 'item_id', 'item_parent_id', 'user_id'],
+				],
+			],
+		];
 	}
 
 	public function revert_schema()
 	{
-		return array(
-			'drop_tables' => array(
-				$this->table_prefix . 'email_notifications',
-			),
-		);
+		return [
+			'drop_tables' => [$this->table_prefix . 'email_notifications'],
+		];
 	}
 }