Update duration from feed if there is none yet (#6322)
This commit is contained in:
parent
7a2f4771ec
commit
caf49c5da8
@ -128,6 +128,9 @@ public class FeedMedia extends FeedFile implements Playable {
|
|||||||
if (other.size > 0) {
|
if (other.size > 0) {
|
||||||
size = other.size;
|
size = other.size;
|
||||||
}
|
}
|
||||||
|
if (other.duration > 0 && duration <= 0) { // Do not overwrite duration that we measured after downloading
|
||||||
|
duration = other.duration;
|
||||||
|
}
|
||||||
if (other.mime_type != null) {
|
if (other.mime_type != null) {
|
||||||
mime_type = other.mime_type;
|
mime_type = other.mime_type;
|
||||||
}
|
}
|
||||||
@ -145,6 +148,9 @@ public class FeedMedia extends FeedFile implements Playable {
|
|||||||
if (other.size > 0 && other.size != size) {
|
if (other.size > 0 && other.size != size) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
if (other.duration > 0 && duration <= 0) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user