Code Duplication    Length = 10-13 lines in 2 locations

includes/user/User.php 2 locations

@@ 2013-2022 (lines=10) @@
2010
	 *
2011
	 * @return bool True if locked, false otherwise
2012
	 */
2013
	public function isLocked() {
2014
		if ( $this->mLocked !== null ) {
2015
			return $this->mLocked;
2016
		}
2017
		global $wgAuth;
2018
		$authUser = $wgAuth->getUserInstance( $this );
2019
		$this->mLocked = (bool)$authUser->isLocked();
2020
		Hooks::run( 'UserIsLocked', [ $this, &$this->mLocked ] );
2021
		return $this->mLocked;
2022
	}
2023
2024
	/**
2025
	 * Check if user account is hidden
@@ 2029-2041 (lines=13) @@
2026
	 *
2027
	 * @return bool True if hidden, false otherwise
2028
	 */
2029
	public function isHidden() {
2030
		if ( $this->mHideName !== null ) {
2031
			return $this->mHideName;
2032
		}
2033
		$this->getBlockedStatus();
2034
		if ( !$this->mHideName ) {
2035
			global $wgAuth;
2036
			$authUser = $wgAuth->getUserInstance( $this );
2037
			$this->mHideName = (bool)$authUser->isHidden();
2038
			Hooks::run( 'UserIsHidden', [ $this, &$this->mHideName ] );
2039
		}
2040
		return $this->mHideName;
2041
	}
2042
2043
	/**
2044
	 * Get the user's ID.