diff --git a/beets/mediafile.py b/beets/mediafile.py index 733eaec32..c5e5efefa 100644 --- a/beets/mediafile.py +++ b/beets/mediafile.py @@ -1221,7 +1221,6 @@ class MediaFile(object): if self.mgfile.tags is None: self.mgfile.add_tags() - # FIXME Deprecated. Use `update` instead def save(self, id3v23=False): """Write the object's tags back to the file. @@ -1302,19 +1301,16 @@ class MediaFile(object): For any key in ``dict`` that is also a field to store tags the method retrieves the corresponding value from ``dict`` and - updates the ``MediaFile``. If any of the tags are changed, these - changes are written to the disk. + updates the ``MediaFile``. The changes are then written to the + disk. By default, MP3 files are saved with ID3v2.4 tags. You can use the older ID3v2.3 standard by specifying the `id3v23` option. """ - updated = False for field in self.fields(): - if field in dict and getattr(self, field) != dict[field]: - updated = True + if field in dict: setattr(self, field, dict[field]) - if updated: - self.save(id3v23) + self.save(id3v23) # Field definitions. diff --git a/test/test_mediafile.py b/test/test_mediafile.py index 99fbd4cc4..bcf80ccbe 100644 --- a/test/test_mediafile.py +++ b/test/test_mediafile.py @@ -316,7 +316,7 @@ class ExtendedFieldTestMixin(object): class ReadWriteTestBase(ArtTestMixin, GenreListTestMixin, - LazySaveTestMixin, ExtendedFieldTestMixin): + ExtendedFieldTestMixin): """Test writing and reading tags. Subclasses must set ``extension`` and ``audio_properties``. """