public function set($domain, FilesystemInterface $filesystem)
    {
        if (!preg_match('/^[-_a-zA-Z0-9]+$/', $domain)) {
            throw new \InvalidArgumentException(sprintf(
                'The specified domain "%s" is not a valid domain.',
                $domain
            ));
        }

        $this->filesystems[$domain] = $filesystem;
    }