Code Duplication    Length = 11-11 lines in 3 locations

classes/PodsUI.php 3 locations

@@ 728-738 (lines=11) @@
725
            else
726
                $options[ 'where' ] = array( 'manage' => $deprecated_options[ 'where' ] );
727
        }
728
        if ( isset( $deprecated_options[ 'edit_where' ] ) ) {
729
            /*if ( isset( $options[ 'where' ] ) )
730
                $options[ 'where' ][ 'edit' ] = $deprecated_options[ 'edit_where' ];
731
            else
732
                $options[ 'where' ] = array( 'edit' => $deprecated_options[ 'edit_where' ] );*/
733
734
            if ( isset( $options[ 'restrict' ] ) )
735
                $options[ 'restrict' ][ 'edit' ] = (array) $deprecated_options[ 'edit_where' ];
736
            else
737
                $options[ 'restrict' ] = array( 'edit' => (array) $deprecated_options[ 'edit_where' ] );
738
        }
739
        if ( isset( $deprecated_options[ 'duplicate_where' ] ) ) {
740
            /*if ( isset( $options[ 'where' ] ) )
741
                $options[ 'where' ][ 'duplicate' ] = $deprecated_options[ 'duplicate_where' ];
@@ 739-749 (lines=11) @@
736
            else
737
                $options[ 'restrict' ] = array( 'edit' => (array) $deprecated_options[ 'edit_where' ] );
738
        }
739
        if ( isset( $deprecated_options[ 'duplicate_where' ] ) ) {
740
            /*if ( isset( $options[ 'where' ] ) )
741
                $options[ 'where' ][ 'duplicate' ] = $deprecated_options[ 'duplicate_where' ];
742
            else
743
                $options[ 'where' ] = array( 'duplicate' => $deprecated_options[ 'duplicate_where' ] );*/
744
745
            if ( isset( $options[ 'restrict' ] ) )
746
                $options[ 'restrict' ][ 'duplicate' ] = (array) $deprecated_options[ 'duplicate_where' ];
747
            else
748
                $options[ 'restrict' ] = array( 'duplicate' => (array) $deprecated_options[ 'duplicate_where' ] );
749
        }
750
        if ( isset( $deprecated_options[ 'delete_where' ] ) ) {
751
            /*if ( isset( $options[ 'where' ] ) )
752
                $options[ 'where' ][ 'delete' ] = $deprecated_options[ 'delete_where' ];
@@ 750-760 (lines=11) @@
747
            else
748
                $options[ 'restrict' ] = array( 'duplicate' => (array) $deprecated_options[ 'duplicate_where' ] );
749
        }
750
        if ( isset( $deprecated_options[ 'delete_where' ] ) ) {
751
            /*if ( isset( $options[ 'where' ] ) )
752
                $options[ 'where' ][ 'delete' ] = $deprecated_options[ 'delete_where' ];
753
            else
754
                $options[ 'where' ] = array( 'delete' => $deprecated_options[ 'delete_where' ] );*/
755
756
            if ( isset( $options[ 'restrict' ] ) )
757
                $options[ 'restrict' ][ 'delete' ] = (array) $deprecated_options[ 'delete_where' ];
758
            else
759
                $options[ 'restrict' ] = array( 'delete' => (array) $deprecated_options[ 'delete_where' ] );
760
        }
761
        if ( isset( $deprecated_options[ 'reorder_where' ] ) ) {
762
            if ( isset( $options[ 'where' ] ) )
763
                $options[ 'where' ][ 'reorder' ] = $deprecated_options[ 'reorder_where' ];