PluginProbe
Image Optimizer – Compress Images and Convert to WebP or AVIF / trunk
Image Optimizer – Compress Images and Convert to WebP or AVIF vtrunk
1.7.7 1.7.6 1.7.5 1.7.4 trunk 1.0.0 1.0.1 1.0.2 1.1.0 1.2.0 1.2.1 1.3.0 1.4.0 1.4.1 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4 1.6.0 1.6.1 1.6.2 1.6.3 1.6.4 1.6.5 All 33 releases
← All changes | modules/oauth/classes/route-base.php +0 -14 1.6.5 → trunk View file →
@@ -33,19 +33,5 @@
33 33 $valid = $this->permission_callback( $request );
34 34
35 35 return $valid && user_can( $this->current_user_id, 'manage_options' );
36 36 }
37 -
38 - public function verify_nonce( $nonce = '', $name = '' ) {
39 - if ( ! wp_verify_nonce( sanitize_text_field( wp_unslash( $nonce ) ), $name ) ) {
40 - wp_die( 'Invalid nonce', 'image-optimization' );
41 - }
42 - }
43 -
44 - public function verify_nonce_and_capability( $nonce = '', $name = '', $capability = 'manage_options' ) {
45 - $this->verify_nonce( $nonce, $name );
46 -
47 - if ( ! current_user_can( $capability ) ) {
48 - wp_die( 'You do not have sufficient permissions to access this page.' );
49 - }
50 - }
51 37 }