Code Duplication    Length = 5-5 lines in 2 locations

includes/Title.php 2 locations

@@ 1954-1958 (lines=5) @@
1951
				$errors[] = $user->isAnon() ? [ 'nocreatetext' ] : [ 'nocreate-loggedin' ];
1952
			}
1953
		} elseif ( $action == 'move' ) {
1954
			if ( !$user->isAllowed( 'move-rootuserpages' )
1955
					&& $this->mNamespace == NS_USER && !$this->isSubpage() ) {
1956
				// Show user page-specific message only if the user can move other pages
1957
				$errors[] = [ 'cant-move-user-page' ];
1958
			}
1959
1960
			// Check if user is allowed to move files if it's a file
1961
			if ( $this->mNamespace == NS_FILE && !$user->isAllowed( 'movefile' ) ) {
@@ 1985-1989 (lines=5) @@
1982
			if ( !$user->isAllowed( 'move' ) ) {
1983
				// User can't move anything
1984
				$errors[] = [ 'movenotallowed' ];
1985
			} elseif ( !$user->isAllowed( 'move-rootuserpages' )
1986
					&& $this->mNamespace == NS_USER && !$this->isSubpage() ) {
1987
				// Show user page-specific message only if the user can move other pages
1988
				$errors[] = [ 'cant-move-to-user-page' ];
1989
			} elseif ( !$user->isAllowed( 'move-categorypages' )
1990
					&& $this->mNamespace == NS_CATEGORY ) {
1991
				// Show category page-specific message only if the user can move other pages
1992
				$errors[] = [ 'cant-move-to-category-page' ];