404

[ Avaa Bypassed ]




Upload:

Command:

elspacio@3.145.85.123: ~ $
<?php

declare(strict_types=1);

namespace Ramsey\Uuid\StaticAnalysis;

use InvalidArgumentException;
use Ramsey\Uuid\Uuid;

final class ValidUuidIsNonEmpty
{
    /** @return non-empty-string */
    public function validUuidsAreNotEmpty(string $input): string
    {
        if (Uuid::isValid($input)) {
            return $input;
        }

        throw new InvalidArgumentException('Not a UUID');
    }

    /**
     * @param non-empty-string $input
     *
     * @return non-empty-string
     */
    public function givenNonEmptyInputAssertionRemainsValid(string $input): string
    {
        if (Uuid::isValid($input)) {
            return $input;
        }

        throw new InvalidArgumentException('Not a UUID');
    }

    public function givenInvalidInputValueRemainsAString(string $input): string
    {
        if (Uuid::isValid($input)) {
            return 'It Worked!';
        }

        return $input;
    }
}

Filemanager

Name Type Size Permission Actions
UuidIsImmutable.php File 3.07 KB 0644
UuidIsNeverEmpty.php File 942 B 0644
ValidUuidIsNonEmpty.php File 970 B 0644
stubs.php File 990 B 0644