| @@ -9,14 +9,14 @@ | ||
| 9 | 9 | * to be "new". |
| 10 | 10 | */ |
| 11 | 11 | class Badge_Group_Names { |
| 12 | 12 | |
| 13 | - const GROUP_GLOBAL_TEMPLATES = 'global-templates'; | |
| 13 | + public const GROUP_GLOBAL_TEMPLATES = 'global-templates'; | |
| 14 | 14 | |
| 15 | 15 | /** |
| 16 | 16 | * Constant describing when certain groups of new badges will no longer be shown. |
| 17 | 17 | */ |
| 18 | - const GROUP_NAMES = [ | |
| 18 | + public const GROUP_NAMES = [ | |
| 19 | 19 | self::GROUP_GLOBAL_TEMPLATES => '16.7-beta0', |
| 20 | 20 | ]; |
| 21 | 21 | |
| 22 | 22 | /** |
| @@ -52,11 +52,9 @@ | ||
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | $group_version = $this::GROUP_NAMES[ $group ]; |
| 55 | 55 | |
| 56 | - if ( \is_null( $current_version ) ) { | |
| 57 | - $current_version = $this->version; | |
| 58 | - } | |
| 56 | + $current_version ??= $this->version; | |
| 59 | 57 | |
| 60 | 58 | return (bool) \version_compare( $group_version, $current_version, '>' ); |
| 61 | 59 | } |
| 62 | 60 | } |