@@ -140,5 +140,5 @@ |
||
140 | 140 | } |
141 | 141 | } |
142 | 142 | add_action( 'widgets_init', function(){ |
143 | - register_widget( '\PodloveSubscribeButton\Podlove_Subscribe_Button_Widget' ); |
|
143 | + register_widget( '\PodloveSubscribeButton\Podlove_Subscribe_Button_Widget' ); |
|
144 | 144 | }); |
145 | 145 | \ No newline at end of file |
@@ -2,7 +2,7 @@ discard block |
||
2 | 2 | namespace PodloveSubscribeButton; |
3 | 3 | |
4 | 4 | if( ! class_exists( 'WP_List_Table' ) ){ |
5 | - require_once( ABSPATH . 'wp-admin/includes/class-wp-list-table.php' ); |
|
5 | + require_once( ABSPATH . 'wp-admin/includes/class-wp-list-table.php' ); |
|
6 | 6 | } |
7 | 7 | |
8 | 8 | class Button_List_Table extends \WP_List_Table { |
@@ -12,9 +12,9 @@ discard block |
||
12 | 12 | |
13 | 13 | // Set parent defaults |
14 | 14 | parent::__construct( array( |
15 | - 'singular' => 'feed', // singular name of the listed records |
|
16 | - 'plural' => 'feeds', // plural name of the listed records |
|
17 | - 'ajax' => false // does this table support ajax? |
|
15 | + 'singular' => 'feed', // singular name of the listed records |
|
16 | + 'plural' => 'feeds', // plural name of the listed records |
|
17 | + 'ajax' => false // does this table support ajax? |
|
18 | 18 | ) ); |
19 | 19 | } |
20 | 20 | |
@@ -26,8 +26,8 @@ discard block |
||
26 | 26 | ); |
27 | 27 | |
28 | 28 | return sprintf('%1$s %2$s', |
29 | - /*$1%s*/ $button->title . '<br><code>[podlove-subscribe-button button="' . $button->name . '"]</code>', |
|
30 | - /*$3%s*/ $this->row_actions( $actions ) |
|
29 | + /*$1%s*/ $button->title . '<br><code>[podlove-subscribe-button button="' . $button->name . '"]</code>', |
|
30 | + /*$3%s*/ $this->row_actions( $actions ) |
|
31 | 31 | ); |
32 | 32 | } |
33 | 33 | |
@@ -83,9 +83,9 @@ discard block |
||
83 | 83 | |
84 | 84 | // register pagination options & calculations |
85 | 85 | $this->set_pagination_args( array( |
86 | - 'total_items' => $total_items, |
|
87 | - 'per_page' => $per_page, |
|
88 | - 'total_pages' => ceil( $total_items / $per_page ) |
|
86 | + 'total_items' => $total_items, |
|
87 | + 'per_page' => $per_page, |
|
88 | + 'total_pages' => ceil( $total_items / $per_page ) |
|
89 | 89 | ) ); |
90 | 90 | } |
91 | 91 |
@@ -389,14 +389,14 @@ discard block |
||
389 | 389 | $this->set_defaults(); |
390 | 390 | |
391 | 391 | $sql = 'INSERT INTO ' |
392 | - . static::table_name() |
|
393 | - . ' ( ' |
|
394 | - . implode( ',', static::property_names() ) |
|
395 | - . ' ) ' |
|
396 | - . 'VALUES' |
|
397 | - . ' ( ' |
|
398 | - . implode( ',', array_map( array( $this, 'property_name_to_sql_value' ), static::property_names() ) ) |
|
399 | - . ' );' |
|
392 | + . static::table_name() |
|
393 | + . ' ( ' |
|
394 | + . implode( ',', static::property_names() ) |
|
395 | + . ' ) ' |
|
396 | + . 'VALUES' |
|
397 | + . ' ( ' |
|
398 | + . implode( ',', array_map( array( $this, 'property_name_to_sql_value' ), static::property_names() ) ) |
|
399 | + . ' );' |
|
400 | 400 | ; |
401 | 401 | $success = $wpdb->query( $sql ); |
402 | 402 | if ( $success ) { |
@@ -404,9 +404,9 @@ discard block |
||
404 | 404 | } |
405 | 405 | } else { |
406 | 406 | $sql = 'UPDATE ' . static::table_name() |
407 | - . ' SET ' |
|
408 | - . implode( ',', array_map( array( $this, 'property_name_to_sql_update_statement' ), static::property_names() ) ) |
|
409 | - . ' WHERE id = ' . $this->id |
|
407 | + . ' SET ' |
|
408 | + . implode( ',', array_map( array( $this, 'property_name_to_sql_update_statement' ), static::property_names() ) ) |
|
409 | + . ' WHERE id = ' . $this->id |
|
410 | 410 | ; |
411 | 411 | |
412 | 412 | $success = $wpdb->query( $sql ); |
@@ -454,13 +454,13 @@ discard block |
||
454 | 454 | global $wpdb; |
455 | 455 | |
456 | 456 | $sql = 'DELETE FROM ' |
457 | - . static::table_name() |
|
458 | - . ' WHERE id = ' . $this->id; |
|
457 | + . static::table_name() |
|
458 | + . ' WHERE id = ' . $this->id; |
|
459 | 459 | |
460 | 460 | $rows_affected = $wpdb->query( $sql ); |
461 | 461 | |
462 | - do_action('podlove_model_delete', $this); |
|
463 | - do_action('podlove_model_change', $this); |
|
462 | + do_action('podlove_model_delete', $this); |
|
463 | + do_action('podlove_model_change', $this); |
|
464 | 464 | |
465 | 465 | return $rows_affected !== false; |
466 | 466 | } |
@@ -499,10 +499,10 @@ discard block |
||
499 | 499 | $property_sql[] = "`{$property['name']}` {$property['type']}"; |
500 | 500 | |
501 | 501 | $sql = 'CREATE TABLE IF NOT EXISTS ' |
502 | - . static::table_name() |
|
503 | - . ' (' |
|
504 | - . implode( ',', $property_sql ) |
|
505 | - . ' ) CHARACTER SET utf8;' |
|
502 | + . static::table_name() |
|
503 | + . ' (' |
|
504 | + . implode( ',', $property_sql ) |
|
505 | + . ' ) CHARACTER SET utf8;' |
|
506 | 506 | ; |
507 | 507 | |
508 | 508 | $wpdb->query( $sql ); |