JamesMoss\Flywheel\Repository::validateName PHP 메소드

validateName() 보호된 메소드

Validates the name of the repo to ensure it can be stored in the filesystem.
protected validateName ( string $name ) : boolean
$name string The name to validate against
리턴 boolean Returns true if valid. Throws an exception if not.
    protected function validateName($name)
    {
        if (!preg_match('/^[0-9A-Za-z\\_\\-]{1,63}$/', $name)) {
            throw new \Exception(sprintf('`%s` is not a valid repository name.', $name));
        }
        return true;
    }