mirror of
https://github.com/BlackLight/micmon.git
synced 2024-11-27 22:25:13 +01:00
Fixing AttributeError
Calling AudioFile(audio_dir) where audio_dir is a AudioDirectory object was causing an AttributeError, since the audio_file variable was being replaced by a string, before the labels_file variable was read out from it.
This commit is contained in:
parent
007456d5ad
commit
a7d9bdcb24
1 changed files with 1 additions and 1 deletions
|
@ -15,8 +15,8 @@ class AudioFile(AudioSource):
|
||||||
*args, **kwargs):
|
*args, **kwargs):
|
||||||
super().__init__(*args, **kwargs)
|
super().__init__(*args, **kwargs)
|
||||||
if isinstance(audio_file, AudioDirectory):
|
if isinstance(audio_file, AudioDirectory):
|
||||||
audio_file = audio_file.audio_file
|
|
||||||
labels_file = audio_file.labels_file
|
labels_file = audio_file.labels_file
|
||||||
|
audio_file = audio_file.audio_file
|
||||||
|
|
||||||
self.audio_file = os.path.abspath(os.path.expanduser(audio_file))
|
self.audio_file = os.path.abspath(os.path.expanduser(audio_file))
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue