def do_stop(self, **kwargs): try: media_file = self.metadata['media_file'] except KeyError: return media_file.scan.set_last_position() DBFacade.commit()
def do_star(self, **kwargs): if self.metadata and 'mmdb' in self.metadata: base_metadata = self.metadata['mmdb'] base_metadata.starred = not base_metadata.starred if base_metadata.starred: log.debug("starred %s" % base_metadata.id) else: log.debug("unstarred %s" % base_metadata.id) DBFacade.commit()