chore: various tweaks
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import json
|
||||
import os
|
||||
import shortuuid
|
||||
import sqlite3
|
||||
|
||||
from typing import List, NamedTuple, Optional
|
||||
@@ -52,6 +53,10 @@ class Status:
|
||||
INTERNAL_SERVER_ERROR = 500
|
||||
|
||||
|
||||
def urlsafe_short_hash() -> str:
|
||||
return shortuuid.uuid()
|
||||
|
||||
|
||||
class MegaEncoder(json.JSONEncoder):
|
||||
def default(self, obj):
|
||||
if isinstance(obj, sqlite3.Row):
|
||||
|
||||
Reference in New Issue
Block a user