@@ 196-200 (lines=5) @@ | ||
193 | // 'likes' are not available in Jetpack |
|
194 | $ordering = isset( $instance['ordering'] ) && 'likes' == $instance['ordering'] ? 'likes' : 'views'; |
|
195 | ||
196 | if ( isset( $instance['display'] ) && in_array( $instance['display'], array( 'grid', 'list', 'text' ) ) ) { |
|
197 | $display = $instance['display']; |
|
198 | } else { |
|
199 | $display = 'text'; |
|
200 | } |
|
201 | ||
202 | if ( 'text' != $display ) { |
|
203 | $get_image_options = array( |
|
@@ 70-74 (lines=5) @@ | ||
67 | // 'likes' are not available in Jetpack |
|
68 | $ordering = isset( $instance['ordering'] ) && 'likes' === $instance['ordering'] ? 'likes' : 'views'; |
|
69 | ||
70 | if ( isset( $instance['display'] ) && in_array( $instance['display'], array( 'grid', 'list', 'text' ) ) ) { |
|
71 | $display = $instance['display']; |
|
72 | } else { |
|
73 | $display = 'text'; |
|
74 | } |
|
75 | ||
76 | ?> |
|
77 | ||
@@ 157-161 (lines=5) @@ | ||
154 | } |
|
155 | } |
|
156 | ||
157 | if ( isset( $new_instance['display'] ) && in_array( $new_instance['display'], array( 'grid', 'list', 'text' ) ) ) { |
|
158 | $instance['display'] = $new_instance['display']; |
|
159 | } else { |
|
160 | $instance['display'] = 'text'; |
|
161 | } |
|
162 | ||
163 | return $instance; |
|
164 | } |