Code Duplication    Length = 8-8 lines in 4 locations

includes/libs/filebackend/FileBackend.php 4 locations

@@ 817-824 (lines=8) @@
814
	 *   - bypassReadOnly : allow writes in read-only mode (since 1.20)
815
	 * @return StatusValue
816
	 */
817
	final public function prepare( array $params ) {
818
		if ( empty( $params['bypassReadOnly'] ) && $this->isReadOnly() ) {
819
			return $this->newStatus( 'backend-fail-readonly', $this->name, $this->readOnly );
820
		}
821
		/** @noinspection PhpUnusedLocalVariableInspection */
822
		$scope = $this->getScopedPHPBehaviorForOps(); // try to ignore client aborts
823
		return $this->doPrepare( $params );
824
	}
825
826
	/**
827
	 * @see FileBackend::prepare()
@@ 848-855 (lines=8) @@
845
	 *   - bypassReadOnly : allow writes in read-only mode (since 1.20)
846
	 * @return StatusValue
847
	 */
848
	final public function secure( array $params ) {
849
		if ( empty( $params['bypassReadOnly'] ) && $this->isReadOnly() ) {
850
			return $this->newStatus( 'backend-fail-readonly', $this->name, $this->readOnly );
851
		}
852
		/** @noinspection PhpUnusedLocalVariableInspection */
853
		$scope = $this->getScopedPHPBehaviorForOps(); // try to ignore client aborts
854
		return $this->doSecure( $params );
855
	}
856
857
	/**
858
	 * @see FileBackend::secure()
@@ 881-888 (lines=8) @@
878
	 * @return StatusValue
879
	 * @since 1.20
880
	 */
881
	final public function publish( array $params ) {
882
		if ( empty( $params['bypassReadOnly'] ) && $this->isReadOnly() ) {
883
			return $this->newStatus( 'backend-fail-readonly', $this->name, $this->readOnly );
884
		}
885
		/** @noinspection PhpUnusedLocalVariableInspection */
886
		$scope = $this->getScopedPHPBehaviorForOps(); // try to ignore client aborts
887
		return $this->doPublish( $params );
888
	}
889
890
	/**
891
	 * @see FileBackend::publish()
@@ 907-914 (lines=8) @@
904
	 *   - bypassReadOnly : allow writes in read-only mode (since 1.20)
905
	 * @return StatusValue
906
	 */
907
	final public function clean( array $params ) {
908
		if ( empty( $params['bypassReadOnly'] ) && $this->isReadOnly() ) {
909
			return $this->newStatus( 'backend-fail-readonly', $this->name, $this->readOnly );
910
		}
911
		/** @noinspection PhpUnusedLocalVariableInspection */
912
		$scope = $this->getScopedPHPBehaviorForOps(); // try to ignore client aborts
913
		return $this->doClean( $params );
914
	}
915
916
	/**
917
	 * @see FileBackend::clean()