Skip to content

Commit

Permalink
Use less error-prone empty body for abstractmethod (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
megabyde committed May 22, 2024
1 parent a807ccf commit ea6066f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions media_player.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ class IMediaPlayer(ABC):

@abstractmethod
def play_audio(self):
pass
raise NotImplementedError

@abstractmethod
def display_video(self):
pass
raise NotImplementedError

@abstractmethod
def view_image(self):
pass
raise NotImplementedError


class AudioPlayer(IMediaPlayer):
Expand Down Expand Up @@ -65,6 +65,6 @@ def view_image(self):
class MediaListPlayer:

def play_list(self, media_list, players):
for i in range(len(media_list)):
for media in media_list:
# Implementation...
pass

0 comments on commit ea6066f

Please sign in to comment.