| @@ -103,12 +103,14 @@ | ||
| 103 | 103 | * |
| 104 | 104 | * @return bool |
| 105 | 105 | */ |
| 106 | 106 | public function is_active(): bool { |
| 107 | - return (bool) apply_filters( | |
| 107 | + $active = apply_filters( | |
| 108 | 108 | 'wd_password_reset_active', |
| 109 | 109 | $this->expire_force && count( $this->user_roles ) > 0 && $this->force_time > 0 |
| 110 | 110 | ); |
| 111 | + | |
| 112 | + return is_bool( $active ) ? $active : (bool) $active; | |
| 111 | 113 | } |
| 112 | 114 | |
| 113 | 115 | /** |
| 114 | 116 | * Returns the module name for Password Reset. |