mirror of
https://github.com/phpbb/phpbb.git
synced 2025-02-24 20:13:22 +01:00
[feature/system-cron] Cast result in cron_manager::is_valid_name() to bool.
PHPBB3-9596
This commit is contained in:
parent
f4f8523ca3
commit
3c0561b68f
@ -100,11 +100,11 @@ class phpbb_cron_manager
|
||||
*
|
||||
* @param string $name Name to check
|
||||
*
|
||||
* @return int
|
||||
* @return bool
|
||||
*/
|
||||
public function is_valid_name($name)
|
||||
{
|
||||
return preg_match('/^[a-zA-Z][a-zA-Z0-9_]*$/', $name);
|
||||
return (bool) preg_match('/^[a-zA-Z][a-zA-Z0-9_]*$/', $name);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user