mirror of
https://github.com/mitb-archive/filebot
synced 2024-12-23 16:28:51 -05:00
* set xattr only for episode/movie files
This commit is contained in:
parent
61bd6f1d9e
commit
59a2dbaf27
@ -836,17 +836,16 @@ public class MediaDetection {
|
||||
|
||||
|
||||
public static void storeMetaInfo(File file, Object model) {
|
||||
// only for Episode / Movie objects
|
||||
if (model instanceof Episode || model instanceof Movie) {
|
||||
MetaAttributes xattr = new MetaAttributes(file);
|
||||
|
||||
// store original name and model as xattr
|
||||
try {
|
||||
if (model instanceof Episode || model instanceof Movie) {
|
||||
xattr.setMetaData(model);
|
||||
|
||||
if (xattr.getOriginalName() == null) {
|
||||
xattr.setOriginalName(file.getName());
|
||||
}
|
||||
}
|
||||
xattr.setMetaData(model);
|
||||
} catch (Exception e) {
|
||||
Logger.getLogger(MediaDetection.class.getClass().getName()).warning("Failed to set xattr: " + e.getMessage());
|
||||
}
|
||||
@ -868,5 +867,5 @@ public class MediaDetection {
|
||||
Logger.getLogger(MediaDetection.class.getClass().getName()).warning("Failed to set creation date: " + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user