mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-06 05:47:53 +00:00
Various small fixes, setting guild config now works
This commit is contained in:
parent
2038f023a0
commit
c875c8af9f
9 changed files with 56 additions and 70 deletions
|
|
@ -20,31 +20,4 @@ namespace PluralKit.Core
|
|||
Interlocked.Decrement(ref _connectionCount);
|
||||
}
|
||||
}
|
||||
|
||||
public class PassthroughTypeHandler<T>: SqlMapper.TypeHandler<T>
|
||||
{
|
||||
public override void SetValue(IDbDataParameter parameter, T value)
|
||||
{
|
||||
parameter.Value = value;
|
||||
}
|
||||
|
||||
public override T Parse(object value)
|
||||
{
|
||||
return (T) value;
|
||||
}
|
||||
}
|
||||
|
||||
public class UlongEncodeAsLongHandler: SqlMapper.TypeHandler<ulong>
|
||||
{
|
||||
public override ulong Parse(object value)
|
||||
{
|
||||
// Cast to long to unbox, then to ulong (???)
|
||||
return (ulong) (long) value;
|
||||
}
|
||||
|
||||
public override void SetValue(IDbDataParameter parameter, ulong value)
|
||||
{
|
||||
parameter.Value = (long) value;
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue