mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-07-09 03:04:20 -04:00
Removing usless | at the begining of externals id
This commit is contained in:
parent
e2f76b62e2
commit
5aa222d799
@ -1,6 +1,7 @@
|
|||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
|
||||||
namespace Kyoo.Models
|
namespace Kyoo.Models
|
||||||
{
|
{
|
||||||
@ -103,7 +104,7 @@ namespace Kyoo.Models
|
|||||||
if (Runtime == -1)
|
if (Runtime == -1)
|
||||||
Runtime = other.Runtime;
|
Runtime = other.Runtime;
|
||||||
ImgPrimary ??= other.ImgPrimary;
|
ImgPrimary ??= other.ImgPrimary;
|
||||||
ExternalIDs = string.Join('|', ExternalIDs, other.ExternalIDs);
|
ExternalIDs = string.Join('|', new [] { ExternalIDs, other.ExternalIDs }.Where(x => !string.IsNullOrEmpty(x)));
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
namespace Kyoo.Models
|
namespace Kyoo.Models
|
||||||
@ -29,7 +30,7 @@ namespace Kyoo.Models
|
|||||||
Slug ??= other.Slug;
|
Slug ??= other.Slug;
|
||||||
Name ??= other.Name;
|
Name ??= other.Name;
|
||||||
ImgPrimary ??= other.ImgPrimary;
|
ImgPrimary ??= other.ImgPrimary;
|
||||||
ExternalIDs += '|' + other.ExternalIDs;
|
ExternalIDs = string.Join('|', new [] { ExternalIDs, other.ExternalIDs }.Where(x => !string.IsNullOrEmpty(x)));
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
namespace Kyoo.Models
|
namespace Kyoo.Models
|
||||||
@ -44,7 +45,7 @@ namespace Kyoo.Models
|
|||||||
Overview ??= other.Overview;
|
Overview ??= other.Overview;
|
||||||
Year ??= other.Year;
|
Year ??= other.Year;
|
||||||
ImgPrimary ??= other.ImgPrimary;
|
ImgPrimary ??= other.ImgPrimary;
|
||||||
ExternalIDs = string.Join('|', ExternalIDs, other.ExternalIDs);
|
ExternalIDs = string.Join('|', new [] { ExternalIDs, other.ExternalIDs }.Where(x => !string.IsNullOrEmpty(x)));
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -123,7 +123,7 @@ namespace Kyoo.Models
|
|||||||
ImgBackdrop ??= other.ImgBackdrop;
|
ImgBackdrop ??= other.ImgBackdrop;
|
||||||
if (other.Studio != null)
|
if (other.Studio != null)
|
||||||
Studio ??= other.Studio;
|
Studio ??= other.Studio;
|
||||||
ExternalIDs = string.Join('|', ExternalIDs, other.ExternalIDs);
|
ExternalIDs = string.Join('|', new [] { ExternalIDs, other.ExternalIDs }.Where(x => !string.IsNullOrEmpty(x)));
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user