protected static function writeSaltToFile(string $salt): void
    {
        static::validateSalt($salt);
        $result = @file_put_contents(static::$saltFile, $salt);

        if (($result === false) || ($result <> strlen($salt))) {
            throw new InvalidArgumentException("Failed to write salt to file [" . static::$saltFile . "]");
        }
    }
protected static function writeSaltToFile(string $salt): void
    {
        static::validateSalt($salt);
        $result = @file_put_contents(static::$saltFile, $salt);

        if (($result === false) || ($result <> strlen($salt))) {
            throw new InvalidArgumentException("Failed to write salt to file [" . static::$saltFile . "]");
        }
    }
protected static function writeSaltToFile ( string $ salt ) : void { static :: validateSalt ( $ salt ) ; $ result = @ file_put_contents ( static :: $ saltFile , $ salt ) ; if ( ( $ result === false ) || ( $ result <> strlen ( $ salt ) ) ) { throw new InvalidArgumentException ( "Failed to write salt to file [" . static :: $ saltFile . "]" ) ; } }
Write a valid salt string to file

@throws \InvalidArgumentException when storing fails
@param string $salt Valid salt string
@return void
Write a valid salt string to file