New property for songs: has_subtitles
This commit is contained in:
		
							parent
							
								
									b4fdf6dafb
								
							
						
					
					
						commit
						132ed675e7
					
				|  | @ -109,11 +109,13 @@ class Song: | |||
|             self.karaoke_ass = karaoke_ass | ||||
|             generate_karaoke_ass(str(karaoke_template_file), str(self.ass), str(karaoke_ass)) | ||||
| 
 | ||||
|     @property | ||||
|     def has_subtitles(self): | ||||
|         return self.ass or self.srt or self.vtt | ||||
| 
 | ||||
|     @property | ||||
|     def publish(self): | ||||
|         has_subtitles = self.ass or self.srt or self.vtt | ||||
|         has_video = self.video | ||||
|         return has_video and has_subtitles | ||||
|         return self.video and self.has_subtitles | ||||
| 
 | ||||
|     @property | ||||
|     def pending(self): | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue