@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | */ |
| 40 | 40 | include_once WORDPOINTS_DIR . 'components/ranks/includes/deprecated.php'; |
| 41 | 41 | |
| 42 | -if ( wordpoints_component_is_active( 'points' ) ) { |
|
| 42 | +if (wordpoints_component_is_active('points')) { |
|
| 43 | 43 | |
| 44 | 44 | /** |
| 45 | 45 | * Ranks integration with the Points component. |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | include_once WORDPOINTS_DIR . 'components/ranks/includes/integration/points.php'; |
| 50 | 50 | } |
| 51 | 51 | |
| 52 | -if ( is_admin() ) { |
|
| 52 | +if (is_admin()) { |
|
| 53 | 53 | |
| 54 | 54 | /** |
| 55 | 55 | * Administration-side rank code. |
@@ -17,7 +17,7 @@ |
||
| 17 | 17 | */ |
| 18 | 18 | function wordpoints_ranks_get_db_schema() { |
| 19 | 19 | |
| 20 | - _deprecated_function( __FUNCTION__, '2.0.0' ); |
|
| 20 | + _deprecated_function(__FUNCTION__, '2.0.0'); |
|
| 21 | 21 | |
| 22 | 22 | global $wpdb; |
| 23 | 23 | |
@@ -32,7 +32,7 @@ discard block |
||
| 32 | 32 | * |
| 33 | 33 | * @return array|false The validated metadata or false if it should't be saved. |
| 34 | 34 | */ |
| 35 | - public function validate_rank_meta( array $meta ) { |
|
| 35 | + public function validate_rank_meta(array $meta) { |
|
| 36 | 36 | return $meta; |
| 37 | 37 | } |
| 38 | 38 | |
@@ -52,7 +52,7 @@ discard block |
||
| 52 | 52 | * |
| 53 | 53 | * @return bool Whether the user meets the requirements for this rank. |
| 54 | 54 | */ |
| 55 | - protected function can_transition_user_rank( $user_id, $rank, array $args ) { |
|
| 55 | + protected function can_transition_user_rank($user_id, $rank, array $args) { |
|
| 56 | 56 | return true; |
| 57 | 57 | } |
| 58 | 58 | } |
@@ -75,17 +75,17 @@ discard block |
||
| 75 | 75 | * |
| 76 | 76 | * @param int|WordPoints_Rank $id The ID of a rank. |
| 77 | 77 | */ |
| 78 | - public function __construct( $id ) { |
|
| 78 | + public function __construct($id) { |
|
| 79 | 79 | |
| 80 | - if ( is_a( $id, __CLASS__ ) ) { |
|
| 81 | - $this->init( $id->data ); |
|
| 80 | + if (is_a($id, __CLASS__)) { |
|
| 81 | + $this->init($id->data); |
|
| 82 | 82 | return; |
| 83 | 83 | } |
| 84 | 84 | |
| 85 | - $id = wordpoints_int( $id ); |
|
| 85 | + $id = wordpoints_int($id); |
|
| 86 | 86 | |
| 87 | - if ( $id ) { |
|
| 88 | - $this->init( self::get_data( $id ) ); |
|
| 87 | + if ($id) { |
|
| 88 | + $this->init(self::get_data($id)); |
|
| 89 | 89 | } |
| 90 | 90 | } |
| 91 | 91 | |
@@ -94,13 +94,13 @@ discard block |
||
| 94 | 94 | * |
| 95 | 95 | * @since 1.7.0 |
| 96 | 96 | */ |
| 97 | - public function __isset( $key ) { |
|
| 97 | + public function __isset($key) { |
|
| 98 | 98 | |
| 99 | - if ( isset( $this->data->$key ) ) { |
|
| 99 | + if (isset($this->data->$key)) { |
|
| 100 | 100 | return true; |
| 101 | 101 | } |
| 102 | 102 | |
| 103 | - return metadata_exists( 'wordpoints_rank', $this->ID, $key ); |
|
| 103 | + return metadata_exists('wordpoints_rank', $this->ID, $key); |
|
| 104 | 104 | } |
| 105 | 105 | |
| 106 | 106 | /** |
@@ -108,14 +108,14 @@ discard block |
||
| 108 | 108 | * |
| 109 | 109 | * @since 1.7.0 |
| 110 | 110 | */ |
| 111 | - public function __get( $key ) { |
|
| 111 | + public function __get($key) { |
|
| 112 | 112 | |
| 113 | - if ( 'ID' === $key ) { |
|
| 113 | + if ('ID' === $key) { |
|
| 114 | 114 | return $this->ID; |
| 115 | - } elseif ( isset( $this->data->$key ) ) { |
|
| 115 | + } elseif (isset($this->data->$key)) { |
|
| 116 | 116 | $value = $this->data->$key; |
| 117 | 117 | } else { |
| 118 | - $value = wordpoints_get_rank_meta( $this->ID, $key, true ); |
|
| 118 | + $value = wordpoints_get_rank_meta($this->ID, $key, true); |
|
| 119 | 119 | } |
| 120 | 120 | |
| 121 | 121 | return $value; |
@@ -126,9 +126,9 @@ discard block |
||
| 126 | 126 | * |
| 127 | 127 | * @since 1.7.0 |
| 128 | 128 | */ |
| 129 | - public function __set( $key, $value ) { |
|
| 129 | + public function __set($key, $value) { |
|
| 130 | 130 | |
| 131 | - if ( 'ID' !== $key && 'data' !== $key ) { |
|
| 131 | + if ('ID' !== $key && 'data' !== $key) { |
|
| 132 | 132 | |
| 133 | 133 | _doing_it_wrong( |
| 134 | 134 | __METHOD__ |
@@ -145,9 +145,9 @@ discard block |
||
| 145 | 145 | * |
| 146 | 146 | * @param object $data The data for a rank. |
| 147 | 147 | */ |
| 148 | - public function init( $data ) { |
|
| 148 | + public function init($data) { |
|
| 149 | 149 | |
| 150 | - if ( ! isset( $data->id ) ) { |
|
| 150 | + if ( ! isset($data->id)) { |
|
| 151 | 151 | return; |
| 152 | 152 | } |
| 153 | 153 | |
@@ -164,7 +164,7 @@ discard block |
||
| 164 | 164 | */ |
| 165 | 165 | public function exists() { |
| 166 | 166 | |
| 167 | - return ! empty( $this->ID ); |
|
| 167 | + return ! empty($this->ID); |
|
| 168 | 168 | } |
| 169 | 169 | |
| 170 | 170 | /** |
@@ -181,23 +181,23 @@ discard block |
||
| 181 | 181 | * |
| 182 | 182 | * @return WordPoints_Rank|false The adjacent rank, or false. |
| 183 | 183 | */ |
| 184 | - public function get_adjacent( $relative_position ) { |
|
| 184 | + public function get_adjacent($relative_position) { |
|
| 185 | 185 | |
| 186 | - if ( 0 === wordpoints_int( $relative_position ) ) { |
|
| 186 | + if (0 === wordpoints_int($relative_position)) { |
|
| 187 | 187 | return $this; |
| 188 | 188 | } |
| 189 | 189 | |
| 190 | - $group = WordPoints_Rank_Groups::get_group( $this->rank_group ); |
|
| 190 | + $group = WordPoints_Rank_Groups::get_group($this->rank_group); |
|
| 191 | 191 | |
| 192 | - $position = $group->get_rank_position( $this->ID ); |
|
| 192 | + $position = $group->get_rank_position($this->ID); |
|
| 193 | 193 | |
| 194 | - $adjacent_rank_id = $group->get_rank( $position + $relative_position ); |
|
| 194 | + $adjacent_rank_id = $group->get_rank($position + $relative_position); |
|
| 195 | 195 | |
| 196 | - if ( ! $adjacent_rank_id ) { |
|
| 196 | + if ( ! $adjacent_rank_id) { |
|
| 197 | 197 | return false; |
| 198 | 198 | } |
| 199 | 199 | |
| 200 | - return new WordPoints_Rank( $adjacent_rank_id ); |
|
| 200 | + return new WordPoints_Rank($adjacent_rank_id); |
|
| 201 | 201 | } |
| 202 | 202 | |
| 203 | 203 | // |
@@ -213,11 +213,11 @@ discard block |
||
| 213 | 213 | * |
| 214 | 214 | * @return object|false The rank's data, or false if not found. |
| 215 | 215 | */ |
| 216 | - public static function get_data( $id ) { |
|
| 216 | + public static function get_data($id) { |
|
| 217 | 217 | |
| 218 | - $rank_data = wp_cache_get( $id, 'wordpoints_ranks' ); |
|
| 218 | + $rank_data = wp_cache_get($id, 'wordpoints_ranks'); |
|
| 219 | 219 | |
| 220 | - if ( false !== $rank_data ) { |
|
| 220 | + if (false !== $rank_data) { |
|
| 221 | 221 | return $rank_data; |
| 222 | 222 | } |
| 223 | 223 | |
@@ -234,11 +234,11 @@ discard block |
||
| 234 | 234 | ) |
| 235 | 235 | ); |
| 236 | 236 | |
| 237 | - if ( null === $rank_data ) { |
|
| 237 | + if (null === $rank_data) { |
|
| 238 | 238 | return false; |
| 239 | 239 | } |
| 240 | 240 | |
| 241 | - wp_cache_add( $rank_data->id, $rank_data, 'wordpoints_ranks' ); |
|
| 241 | + wp_cache_add($rank_data->id, $rank_data, 'wordpoints_ranks'); |
|
| 242 | 242 | |
| 243 | 243 | return $rank_data; |
| 244 | 244 | } |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | */ |
| 29 | 29 | protected $updates = array( |
| 30 | 30 | '1.8.0' => array( /* - */ 'site' => true, /* - */ ), |
| 31 | - '2.0.0' => array( 'single' => true, /* - */ 'network' => true ), |
|
| 31 | + '2.0.0' => array('single' => true, /* - */ 'network' => true), |
|
| 32 | 32 | ); |
| 33 | 33 | |
| 34 | 34 | /** |
@@ -79,8 +79,8 @@ discard block |
||
| 79 | 79 | */ |
| 80 | 80 | protected function before_update() { |
| 81 | 81 | |
| 82 | - if ( $this->network_wide ) { |
|
| 83 | - unset( $this->updates['1_8_0'] ); |
|
| 82 | + if ($this->network_wide) { |
|
| 83 | + unset($this->updates['1_8_0']); |
|
| 84 | 84 | } |
| 85 | 85 | } |
| 86 | 86 | |
@@ -96,7 +96,7 @@ discard block |
||
| 96 | 96 | */ |
| 97 | 97 | protected function load_dependencies() { |
| 98 | 98 | |
| 99 | - include_once( WORDPOINTS_DIR . 'components/ranks/includes/constants.php' ); |
|
| 99 | + include_once(WORDPOINTS_DIR . 'components/ranks/includes/constants.php'); |
|
| 100 | 100 | } |
| 101 | 101 | |
| 102 | 102 | /** |
@@ -127,7 +127,7 @@ discard block |
||
| 127 | 127 | " |
| 128 | 128 | ); // WPCS: cache pass. |
| 129 | 129 | |
| 130 | - $this->maybe_update_tables_to_utf8mb4( 'global' ); |
|
| 130 | + $this->maybe_update_tables_to_utf8mb4('global'); |
|
| 131 | 131 | } |
| 132 | 132 | |
| 133 | 133 | /** |
@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | * @type string $slug The slug of this rank type. |
| 76 | 76 | * } |
| 77 | 77 | */ |
| 78 | - public function __construct( array $args ) { |
|
| 78 | + public function __construct(array $args) { |
|
| 79 | 79 | |
| 80 | 80 | $this->slug = $args['slug']; |
| 81 | 81 | } |
@@ -109,7 +109,7 @@ discard block |
||
| 109 | 109 | * @return array|WP_Error|false The validated metadata, or false or a WP_Error |
| 110 | 110 | * if it should't be saved. |
| 111 | 111 | */ |
| 112 | - abstract public function validate_rank_meta( array $meta ); |
|
| 112 | + abstract public function validate_rank_meta(array $meta); |
|
| 113 | 113 | |
| 114 | 114 | /** |
| 115 | 115 | * Determine if a user meets the requirements for a rank of this type. |
@@ -126,7 +126,7 @@ discard block |
||
| 126 | 126 | * |
| 127 | 127 | * @return bool Whether the user meets the requirements for this rank. |
| 128 | 128 | */ |
| 129 | - abstract protected function can_transition_user_rank( $user_id, $rank, array $args ); |
|
| 129 | + abstract protected function can_transition_user_rank($user_id, $rank, array $args); |
|
| 130 | 130 | |
| 131 | 131 | // |
| 132 | 132 | // Final Public Methods. |
@@ -185,47 +185,47 @@ discard block |
||
| 185 | 185 | array $args = array() |
| 186 | 186 | ) { |
| 187 | 187 | |
| 188 | - $args = array_merge( array( 'placeholders' => false ), $args ); |
|
| 188 | + $args = array_merge(array('placeholders' => false), $args); |
|
| 189 | 189 | |
| 190 | - foreach ( $this->meta_fields as $name => $field ) { |
|
| 190 | + foreach ($this->meta_fields as $name => $field) { |
|
| 191 | 191 | |
| 192 | 192 | // If we aren't using placeholders, calculate the value. Hidden fields |
| 193 | 193 | // never use placeholders. |
| 194 | - if ( ! $args['placeholders'] || 'hidden' === $field['type'] ) { |
|
| 194 | + if ( ! $args['placeholders'] || 'hidden' === $field['type']) { |
|
| 195 | 195 | |
| 196 | 196 | // Default to the default value. |
| 197 | 197 | $value = $field['default']; |
| 198 | 198 | |
| 199 | 199 | // If the value is set use that instead. |
| 200 | - if ( isset( $meta[ $name ] ) ) { |
|
| 201 | - $value = $meta[ $name ]; |
|
| 200 | + if (isset($meta[$name])) { |
|
| 201 | + $value = $meta[$name]; |
|
| 202 | 202 | } |
| 203 | 203 | } |
| 204 | 204 | |
| 205 | - switch ( $field['type'] ) { |
|
| 205 | + switch ($field['type']) { |
|
| 206 | 206 | |
| 207 | 207 | case 'hidden': |
| 208 | 208 | case 'number': |
| 209 | 209 | case 'text': |
| 210 | - if ( isset( $field['label'] ) ) { |
|
| 210 | + if (isset($field['label'])) { |
|
| 211 | 211 | ?><p class="description description-thin"><label><?php |
| 212 | - echo esc_html( $field['label'] ); |
|
| 212 | + echo esc_html($field['label']); |
|
| 213 | 213 | } |
| 214 | 214 | |
| 215 | 215 | ?> |
| 216 | 216 | <input |
| 217 | - type="<?php echo esc_attr( $field['type'] ); ?>" |
|
| 218 | - name="<?php echo esc_attr( $name ); ?>" |
|
| 219 | - <?php if ( $args['placeholders'] && 'hidden' !== $field['type'] ) : ?> |
|
| 220 | - value="<% if ( typeof <?php echo preg_replace( '/[^a-z0-9_]/i', '', $name ); // WPCS: XSS OK ?> !== "undefined" ) { print( <?php echo preg_replace( '/[^a-z0-9_]/i', '', $name ); // WPCS: XSS OK ?> ); } %>" |
|
| 217 | + type="<?php echo esc_attr($field['type']); ?>" |
|
| 218 | + name="<?php echo esc_attr($name); ?>" |
|
| 219 | + <?php if ($args['placeholders'] && 'hidden' !== $field['type']) : ?> |
|
| 220 | + value="<% if ( typeof <?php echo preg_replace('/[^a-z0-9_]/i', '', $name); // WPCS: XSS OK ?> !== "undefined" ) { print( <?php echo preg_replace('/[^a-z0-9_]/i', '', $name); // WPCS: XSS OK ?> ); } %>" |
|
| 221 | 221 | <?php else : ?> |
| 222 | - value="<?php echo esc_attr( $value ); ?>" |
|
| 222 | + value="<?php echo esc_attr($value); ?>" |
|
| 223 | 223 | <?php endif; ?> |
| 224 | 224 | class="widefat" |
| 225 | 225 | /> |
| 226 | 226 | <?php |
| 227 | 227 | |
| 228 | - if ( isset( $field['label'] ) ) { |
|
| 228 | + if (isset($field['label'])) { |
|
| 229 | 229 | ?></label></p><?php |
| 230 | 230 | } |
| 231 | 231 | break; |
@@ -235,7 +235,7 @@ discard block |
||
| 235 | 235 | __METHOD__ |
| 236 | 236 | , sprintf( |
| 237 | 237 | 'WordPoints Error: Unknown field type "%s".' |
| 238 | - , esc_html( $field['type'] ) |
|
| 238 | + , esc_html($field['type']) |
|
| 239 | 239 | ) |
| 240 | 240 | , '1.7.0' |
| 241 | 241 | ); |
@@ -256,21 +256,21 @@ discard block |
||
| 256 | 256 | * |
| 257 | 257 | * @return WordPoints_Rank The highest rank that the user can be increased to. |
| 258 | 258 | */ |
| 259 | - final public function maybe_increase_user_rank( $user_id, $rank, array $args = array() ) { |
|
| 259 | + final public function maybe_increase_user_rank($user_id, $rank, array $args = array()) { |
|
| 260 | 260 | |
| 261 | - $next_rank = $rank->get_adjacent( 1 ); |
|
| 261 | + $next_rank = $rank->get_adjacent(1); |
|
| 262 | 262 | |
| 263 | - if ( ! $next_rank ) { |
|
| 263 | + if ( ! $next_rank) { |
|
| 264 | 264 | return $rank; |
| 265 | 265 | } |
| 266 | 266 | |
| 267 | - $rank_type = WordPoints_Rank_Types::get_type( $next_rank->type ); |
|
| 267 | + $rank_type = WordPoints_Rank_Types::get_type($next_rank->type); |
|
| 268 | 268 | |
| 269 | - if ( ! $rank_type->can_transition_user_rank( $user_id, $next_rank, $args ) ) { |
|
| 269 | + if ( ! $rank_type->can_transition_user_rank($user_id, $next_rank, $args)) { |
|
| 270 | 270 | return $rank; |
| 271 | 271 | } |
| 272 | 272 | |
| 273 | - return $this->maybe_increase_user_rank( $user_id, $next_rank, $args ); |
|
| 273 | + return $this->maybe_increase_user_rank($user_id, $next_rank, $args); |
|
| 274 | 274 | } |
| 275 | 275 | |
| 276 | 276 | /** |
@@ -284,21 +284,21 @@ discard block |
||
| 284 | 284 | * |
| 285 | 285 | * @return WordPoints_Rank The highest rank that the user can have. |
| 286 | 286 | */ |
| 287 | - final public function maybe_decrease_user_rank( $user_id, $rank, array $args = array() ) { |
|
| 287 | + final public function maybe_decrease_user_rank($user_id, $rank, array $args = array()) { |
|
| 288 | 288 | |
| 289 | - $rank_type = WordPoints_Rank_Types::get_type( $rank->type ); |
|
| 289 | + $rank_type = WordPoints_Rank_Types::get_type($rank->type); |
|
| 290 | 290 | |
| 291 | - if ( $rank_type->can_transition_user_rank( $user_id, $rank, $args ) ) { |
|
| 291 | + if ($rank_type->can_transition_user_rank($user_id, $rank, $args)) { |
|
| 292 | 292 | return $rank; |
| 293 | 293 | } |
| 294 | 294 | |
| 295 | 295 | $previous_rank = $rank->get_adjacent( -1 ); |
| 296 | 296 | |
| 297 | - if ( ! $previous_rank ) { |
|
| 297 | + if ( ! $previous_rank) { |
|
| 298 | 298 | return $rank; |
| 299 | 299 | } |
| 300 | 300 | |
| 301 | - return $this->maybe_decrease_user_rank( $user_id, $previous_rank, $args ); |
|
| 301 | + return $this->maybe_decrease_user_rank($user_id, $previous_rank, $args); |
|
| 302 | 302 | } |
| 303 | 303 | |
| 304 | 304 | // |
@@ -322,28 +322,28 @@ discard block |
||
| 322 | 322 | |
| 323 | 323 | $groups = WordPoints_Rank_Groups::get(); |
| 324 | 324 | |
| 325 | - foreach ( $groups as $group_slug => $group ) { |
|
| 325 | + foreach ($groups as $group_slug => $group) { |
|
| 326 | 326 | |
| 327 | - if ( ! WordPoints_Rank_Groups::is_type_registered_for_group( $this->slug, $group_slug ) ) { |
|
| 327 | + if ( ! WordPoints_Rank_Groups::is_type_registered_for_group($this->slug, $group_slug)) { |
|
| 328 | 328 | continue; |
| 329 | 329 | } |
| 330 | 330 | |
| 331 | - $rank_id = wordpoints_get_user_rank( $user_id, $group_slug ); |
|
| 331 | + $rank_id = wordpoints_get_user_rank($user_id, $group_slug); |
|
| 332 | 332 | |
| 333 | - $rank = wordpoints_get_rank( $rank_id ); |
|
| 333 | + $rank = wordpoints_get_rank($rank_id); |
|
| 334 | 334 | |
| 335 | - if ( ! $rank ) { |
|
| 335 | + if ( ! $rank) { |
|
| 336 | 336 | continue; |
| 337 | 337 | } |
| 338 | 338 | |
| 339 | - if ( $increase ) { |
|
| 340 | - $new_rank = $this->maybe_increase_user_rank( $user_id, $rank, $args ); |
|
| 339 | + if ($increase) { |
|
| 340 | + $new_rank = $this->maybe_increase_user_rank($user_id, $rank, $args); |
|
| 341 | 341 | } else { |
| 342 | - $new_rank = $this->maybe_decrease_user_rank( $user_id, $rank, $args ); |
|
| 342 | + $new_rank = $this->maybe_decrease_user_rank($user_id, $rank, $args); |
|
| 343 | 343 | } |
| 344 | 344 | |
| 345 | - if ( $new_rank !== $rank ) { |
|
| 346 | - wordpoints_update_user_rank( $user_id, $new_rank->ID ); |
|
| 345 | + if ($new_rank !== $rank) { |
|
| 346 | + wordpoints_update_user_rank($user_id, $new_rank->ID); |
|
| 347 | 347 | } |
| 348 | 348 | } |
| 349 | 349 | } |
@@ -218,8 +218,11 @@ |
||
| 218 | 218 | name="<?php echo esc_attr( $name ); ?>" |
| 219 | 219 | <?php if ( $args['placeholders'] && 'hidden' !== $field['type'] ) : ?> |
| 220 | 220 | value="<% if ( typeof <?php echo preg_replace( '/[^a-z0-9_]/i', '', $name ); // WPCS: XSS OK ?> !== "undefined" ) { print( <?php echo preg_replace( '/[^a-z0-9_]/i', '', $name ); // WPCS: XSS OK ?> ); } %>" |
| 221 | - <?php else : ?> |
|
| 222 | - value="<?php echo esc_attr( $value ); ?>" |
|
| 221 | + <?php else { |
|
| 222 | + : ?> |
|
| 223 | + value="<?php echo esc_attr( $value ); |
|
| 224 | +} |
|
| 225 | +?>" |
|
| 223 | 226 | <?php endif; ?> |
| 224 | 227 | class="widefat" |
| 225 | 228 | /> |
@@ -12,13 +12,13 @@ |
||
| 12 | 12 | * |
| 13 | 13 | * @since 2.1.0 |
| 14 | 14 | */ |
| 15 | -include_once( WORDPOINTS_DIR . '/components/ranks/includes/integration/points/functions.php' ); |
|
| 15 | +include_once(WORDPOINTS_DIR . '/components/ranks/includes/integration/points/functions.php'); |
|
| 16 | 16 | |
| 17 | 17 | /** |
| 18 | 18 | * Actions and filters to integrate with the points component. |
| 19 | 19 | * |
| 20 | 20 | * @since 2.1.0 |
| 21 | 21 | */ |
| 22 | -include_once( WORDPOINTS_DIR . '/components/ranks/includes/integration/points/filters.php' ); |
|
| 22 | +include_once(WORDPOINTS_DIR . '/components/ranks/includes/integration/points/filters.php'); |
|
| 23 | 23 | |
| 24 | 24 | // EOF |
@@ -7,15 +7,15 @@ |
||
| 7 | 7 | * @since 2.1.0 |
| 8 | 8 | */ |
| 9 | 9 | |
| 10 | -add_filter( 'wordpoints_points_widget_text', 'wordpoints_ranks_points_widget_text_filter', 30, 2 ); |
|
| 11 | -add_action( 'wordpoints_my_points_widget_below_text_field', 'wordpoints_ranks_my_points_widget_below_text_field' ); |
|
| 10 | +add_filter('wordpoints_points_widget_text', 'wordpoints_ranks_points_widget_text_filter', 30, 2); |
|
| 11 | +add_action('wordpoints_my_points_widget_below_text_field', 'wordpoints_ranks_my_points_widget_below_text_field'); |
|
| 12 | 12 | |
| 13 | -add_filter( 'wordpoints_points_top_users_username', 'wordpoints_ranks_points_top_users_username_filter', 10, 4 ); |
|
| 13 | +add_filter('wordpoints_points_top_users_username', 'wordpoints_ranks_points_top_users_username_filter', 10, 4); |
|
| 14 | 14 | |
| 15 | -add_filter( 'shortcode_atts_wordpoints_user_rank', 'wordpoints_user_rank_shortcode_points_type_attr', 10, 3 ); |
|
| 15 | +add_filter('shortcode_atts_wordpoints_user_rank', 'wordpoints_user_rank_shortcode_points_type_attr', 10, 3); |
|
| 16 | 16 | |
| 17 | -add_action( 'wordpoints_ranks_register', 'wordpoints_register_points_ranks' ); |
|
| 17 | +add_action('wordpoints_ranks_register', 'wordpoints_register_points_ranks'); |
|
| 18 | 18 | |
| 19 | -add_action( 'add_meta_boxes', 'wordpoints_ranks_add_points_types_meta_box_ranks', 20 ); |
|
| 19 | +add_action('add_meta_boxes', 'wordpoints_ranks_add_points_types_meta_box_ranks', 20); |
|
| 20 | 20 | |
| 21 | 21 | // EOF |
@@ -8,13 +8,13 @@ |
||
| 8 | 8 | * @deprecated 2.2.0 |
| 9 | 9 | */ |
| 10 | 10 | |
| 11 | -_deprecated_file( __FILE__, '2.2.0' ); |
|
| 11 | +_deprecated_file(__FILE__, '2.2.0'); |
|
| 12 | 12 | |
| 13 | 13 | /** |
| 14 | 14 | * The base rank type class. |
| 15 | 15 | * |
| 16 | 16 | * @since 1.7.0 |
| 17 | 17 | */ |
| 18 | -include_once( WORDPOINTS_DIR . '/components/ranks/includes/rank-types/base.php' ); |
|
| 18 | +include_once(WORDPOINTS_DIR . '/components/ranks/includes/rank-types/base.php'); |
|
| 19 | 19 | |
| 20 | 20 | // EOF |