CacheDriver: moved to subdirectory

This commit is contained in:
Zankaria 2025-07-26 23:34:58 +02:00
parent 8ee471c868
commit 311a5477f8
8 changed files with 8 additions and 8 deletions

View file

@ -1,20 +0,0 @@
<?php
namespace Vichan\Data\Driver;
trait CacheDriverTrait {
/**
* Tries to interpret the uri as a path to a unix socket.
*
* @param string $uri
* @return ?string The path to the socket, null if it cannot be interpreted as such.
*/
private static function asUnixSocketPath(string $uri): ?string {
if (str_starts_with($uri, 'unix:')) {
return \substr($uri, 5);
} elseif (str_starts_with($uri, ':')) {
return \substr($uri, 1);
}
return null;
}
}