瀏覽代碼

[videos] Just a little type hinting

Colin Powell 4 月之前
父節點
當前提交
b660e47bc2
共有 1 個文件被更改,包括 3 次插入1 次删除
  1. 3 1
      vrobbler/apps/videos/models.py

+ 3 - 1
vrobbler/apps/videos/models.py

@@ -306,7 +306,9 @@ class Video(ScrobblableMixin):
         return video
 
     @classmethod
-    def get_from_imdb_id(cls, imdb_id: str, overwrite: bool = False):
+    def get_from_imdb_id(
+        cls, imdb_id: str, overwrite: bool = False
+    ) -> "Video":
         video, created = cls.objects.get_or_create(imdb_id=imdb_id)
         if not created and not overwrite:
             return video