mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-05-30 19:54:16 -04:00
CodingStyle: Adding last \n at end of file
This commit is contained in:
parent
62eec91e6e
commit
fd122592f4
@ -1,7 +1,7 @@
|
|||||||
root = true
|
root = true
|
||||||
|
|
||||||
[*]
|
[*]
|
||||||
charset = us-ascii
|
charset = utf-8
|
||||||
end_of_line = lf
|
end_of_line = lf
|
||||||
trim_trailing_whitespace = true
|
trim_trailing_whitespace = true
|
||||||
insert_final_newline = true
|
insert_final_newline = true
|
||||||
|
@ -248,6 +248,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="id">The ID of the resource</param>
|
/// <param name="id">The ID of the resource</param>
|
||||||
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
||||||
|
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
|
||||||
Task Delete(int id);
|
Task Delete(int id);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -255,6 +256,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="slug">The slug of the resource</param>
|
/// <param name="slug">The slug of the resource</param>
|
||||||
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
||||||
|
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
|
||||||
Task Delete(string slug);
|
Task Delete(string slug);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -262,6 +264,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="obj">The resource to delete</param>
|
/// <param name="obj">The resource to delete</param>
|
||||||
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
||||||
|
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
|
||||||
Task Delete([NotNull] T obj);
|
Task Delete([NotNull] T obj);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -269,6 +272,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="where">A predicate to filter resources to delete. Every resource that match this will be deleted.</param>
|
/// <param name="where">A predicate to filter resources to delete. Every resource that match this will be deleted.</param>
|
||||||
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
/// <exception cref="ItemNotFoundException">If the item is not found</exception>
|
||||||
|
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
|
||||||
Task DeleteAll([NotNull] Expression<Func<T, bool>> where);
|
Task DeleteAll([NotNull] Expression<Func<T, bool>> where);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -284,6 +288,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// <param name="showID">The ID of the show</param>
|
/// <param name="showID">The ID of the show</param>
|
||||||
/// <param name="libraryID">The ID of the library (optional)</param>
|
/// <param name="libraryID">The ID of the library (optional)</param>
|
||||||
/// <param name="collectionID">The ID of the collection (optional)</param>
|
/// <param name="collectionID">The ID of the collection (optional)</param>
|
||||||
|
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
|
||||||
Task AddShowLink(int showID, int? libraryID, int? collectionID);
|
Task AddShowLink(int showID, int? libraryID, int? collectionID);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -624,7 +629,8 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
Task<ICollection<MetadataID>> GetMetadataID<T>([Optional] Expression<Func<MetadataID, bool>> where,
|
Task<ICollection<MetadataID>> GetMetadataID<T>([Optional] Expression<Func<MetadataID, bool>> where,
|
||||||
Expression<Func<MetadataID, object>> sort,
|
Expression<Func<MetadataID, object>> sort,
|
||||||
Pagination limit = default
|
Pagination limit = default
|
||||||
) where T : class, IMetadata
|
)
|
||||||
|
where T : class, IMetadata
|
||||||
=> GetMetadataID<T>(where, new Sort<MetadataID>(sort), limit);
|
=> GetMetadataID<T>(where, new Sort<MetadataID>(sort), limit);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -9,6 +9,43 @@ using Kyoo.Abstractions.Models.Exceptions;
|
|||||||
|
|
||||||
namespace Kyoo.Abstractions.Controllers
|
namespace Kyoo.Abstractions.Controllers
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// A common interface that tasks should implement.
|
||||||
|
/// </summary>
|
||||||
|
public interface ITask
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The list of parameters
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>
|
||||||
|
/// All parameters that this task as. Every one of them will be given to the run function with a value.
|
||||||
|
/// </returns>
|
||||||
|
public TaskParameters GetParameters();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Start this task.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="arguments">
|
||||||
|
/// The list of parameters.
|
||||||
|
/// </param>
|
||||||
|
/// <param name="progress">
|
||||||
|
/// The progress reporter. Used to inform the sender the percentage of completion of this task
|
||||||
|
/// .</param>
|
||||||
|
/// <param name="cancellationToken">A token to request the task's cancellation.
|
||||||
|
/// If this task is not cancelled quickly, it might be killed by the runner.
|
||||||
|
/// </param>
|
||||||
|
/// <exception cref="TaskFailedException">
|
||||||
|
/// An exception meaning that the task has failed for handled reasons like invalid arguments,
|
||||||
|
/// invalid environment, missing plugins or failures not related to a default in the code.
|
||||||
|
/// This exception allow the task to display a failure message to the end user while others exceptions
|
||||||
|
/// will be displayed as unhandled exceptions and display a stack trace.
|
||||||
|
/// </exception>
|
||||||
|
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
|
||||||
|
public Task Run([NotNull] TaskParameters arguments,
|
||||||
|
[NotNull] IProgress<float> progress,
|
||||||
|
CancellationToken cancellationToken);
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// A single task parameter. This struct contains metadata to display and utility functions to get them in the task.
|
/// A single task parameter. This struct contains metadata to display and utility functions to get them in the task.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -43,7 +80,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// The value of the parameter.
|
/// The value of the parameter.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private object Value { get; init; }
|
private object _Value { get; init; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Create a new task parameter.
|
/// Create a new task parameter.
|
||||||
@ -93,7 +130,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
{
|
{
|
||||||
Name = name,
|
Name = name,
|
||||||
Type = typeof(T),
|
Type = typeof(T),
|
||||||
Value = value
|
_Value = value
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -104,7 +141,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// <returns>A new parameter's value for this current parameter</returns>
|
/// <returns>A new parameter's value for this current parameter</returns>
|
||||||
public TaskParameter CreateValue(object value)
|
public TaskParameter CreateValue(object value)
|
||||||
{
|
{
|
||||||
return this with { Value = value };
|
return this with { _Value = value };
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -115,9 +152,9 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
public T As<T>()
|
public T As<T>()
|
||||||
{
|
{
|
||||||
if (typeof(T) == typeof(object))
|
if (typeof(T) == typeof(object))
|
||||||
return (T)Value;
|
return (T)_Value;
|
||||||
|
|
||||||
if (Value is IResource resource)
|
if (_Value is IResource resource)
|
||||||
{
|
{
|
||||||
if (typeof(T) == typeof(string))
|
if (typeof(T) == typeof(string))
|
||||||
return (T)(object)resource.Slug;
|
return (T)(object)resource.Slug;
|
||||||
@ -125,7 +162,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
return (T)(object)resource.ID;
|
return (T)(object)resource.ID;
|
||||||
}
|
}
|
||||||
|
|
||||||
return (T)Convert.ChangeType(Value, typeof(T));
|
return (T)Convert.ChangeType(_Value, typeof(T));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -146,7 +183,7 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
public TaskParameters() { }
|
public TaskParameters() { }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Create a <see cref="TaskParameters"/> with an initial parameters content
|
/// Create a <see cref="TaskParameters"/> with an initial parameters content.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="parameters">The list of parameters</param>
|
/// <param name="parameters">The list of parameters</param>
|
||||||
public TaskParameters(IEnumerable<TaskParameter> parameters)
|
public TaskParameters(IEnumerable<TaskParameter> parameters)
|
||||||
@ -154,40 +191,4 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
AddRange(parameters);
|
AddRange(parameters);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// A common interface that tasks should implement.
|
|
||||||
/// </summary>
|
|
||||||
public interface ITask
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// The list of parameters
|
|
||||||
/// </summary>
|
|
||||||
/// <returns>
|
|
||||||
/// All parameters that this task as. Every one of them will be given to the run function with a value.
|
|
||||||
/// </returns>
|
|
||||||
public TaskParameters GetParameters();
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Start this task.
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="arguments">
|
|
||||||
/// The list of parameters.
|
|
||||||
/// </param>
|
|
||||||
/// <param name="progress">
|
|
||||||
/// The progress reporter. Used to inform the sender the percentage of completion of this task
|
|
||||||
/// .</param>
|
|
||||||
/// <param name="cancellationToken">A token to request the task's cancellation.
|
|
||||||
/// If this task is not cancelled quickly, it might be killed by the runner.
|
|
||||||
/// </param>
|
|
||||||
/// <exception cref="TaskFailedException">
|
|
||||||
/// An exception meaning that the task has failed for handled reasons like invalid arguments,
|
|
||||||
/// invalid environment, missing plugins or failures not related to a default in the code.
|
|
||||||
/// This exception allow the task to display a failure message to the end user while others exceptions
|
|
||||||
/// will be displayed as unhandled exceptions and display a stack trace.
|
|
||||||
/// </exception>
|
|
||||||
public Task Run([NotNull] TaskParameters arguments,
|
|
||||||
[NotNull] IProgress<float> progress,
|
|
||||||
CancellationToken cancellationToken);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@ -79,4 +79,4 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
/// <returns>A list of every tasks that this instance know.</returns>
|
/// <returns>A list of every tasks that this instance know.</returns>
|
||||||
ICollection<TaskMetadataAttribute> GetAllTasks();
|
ICollection<TaskMetadataAttribute> GetAllTasks();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -217,4 +217,4 @@ namespace Kyoo.Abstractions.Controllers
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -14,4 +14,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public T Value { get; set; }
|
public T Value { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,4 +7,4 @@ namespace Kyoo.Abstractions.Models.Attributes
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
[AttributeUsage(AttributeTargets.Property)]
|
[AttributeUsage(AttributeTargets.Property)]
|
||||||
public class ComputedAttribute : NotMergeableAttribute { }
|
public class ComputedAttribute : NotMergeableAttribute { }
|
||||||
}
|
}
|
||||||
|
@ -49,4 +49,4 @@ namespace Kyoo.Abstractions.Models.Attributes
|
|||||||
StripScheme = (bool)metadata[nameof(StripScheme)];
|
StripScheme = (bool)metadata[nameof(StripScheme)];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -19,4 +19,4 @@ namespace Kyoo.Abstractions.Models.Attributes
|
|||||||
/// <param name="merged">The object that has been merged with this.</param>
|
/// <param name="merged">The object that has been merged with this.</param>
|
||||||
void OnMerge(object merged);
|
void OnMerge(object merged);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -34,4 +34,4 @@ namespace Kyoo.Abstractions.Models.Attributes
|
|||||||
RelationID = relationID;
|
RelationID = relationID;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -42,4 +42,4 @@ namespace Kyoo.Abstractions.Models.Attributes
|
|||||||
Format = format;
|
Format = format;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -73,4 +73,4 @@ namespace Kyoo.Abstractions.Models.Attributes
|
|||||||
IsHidden = (bool)metadata[nameof(IsHidden)];
|
IsHidden = (bool)metadata[nameof(IsHidden)];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -92,4 +92,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
return new(path, null);
|
return new(path, null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -33,4 +33,4 @@ namespace Kyoo.Abstractions.Models.Exceptions
|
|||||||
: base(info, context)
|
: base(info, context)
|
||||||
{ }
|
{ }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -42,4 +42,4 @@ namespace Kyoo.Abstractions.Models.Exceptions
|
|||||||
: base(info, context)
|
: base(info, context)
|
||||||
{ }
|
{ }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -141,4 +141,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
Type = ItemType.Collection
|
Type = ItemType.Collection
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -42,4 +42,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
get { return x => new { First = x.ResourceID, Second = x.ProviderID }; }
|
get { return x => new { First = x.ResourceID, Second = x.ProviderID }; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -76,4 +76,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
First = new Uri(url + query.ToQueryString());
|
First = new Uri(url + query.ToQueryString());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -54,4 +54,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string Role { get; set; }
|
public string Role { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,4 +77,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,4 +26,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
/// </remarks>
|
/// </remarks>
|
||||||
public string Slug { get; }
|
public string Slug { get; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -46,4 +46,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public const int Trailer = 3;
|
public const int Trailer = 3;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -61,4 +61,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,4 +77,4 @@ namespace Kyoo.Abstractions.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public int WatchedPercentage { get; set; }
|
public int WatchedPercentage { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -83,4 +83,4 @@ namespace Kyoo.Abstractions
|
|||||||
return configuration["basics:publicUrl"]?.TrimEnd('/') ?? "http://localhost:5000";
|
return configuration["basics:publicUrl"]?.TrimEnd('/') ?? "http://localhost:5000";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -276,4 +276,4 @@ namespace Kyoo.Utils
|
|||||||
yield return ret;
|
yield return ret;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -88,4 +88,4 @@ namespace Kyoo.Utils
|
|||||||
return action.Method;
|
return action.Method;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -66,4 +66,4 @@ namespace Kyoo.Utils
|
|||||||
return value ?? Task.FromResult<T>(default);
|
return value ?? Task.FromResult<T>(default);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -117,4 +117,4 @@ namespace Kyoo.Authentication
|
|||||||
return certificate;
|
return certificate;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -51,4 +51,4 @@ namespace Kyoo.Authentication
|
|||||||
return hash.SequenceEqual(validHash.Skip(16));
|
return hash.SequenceEqual(validHash.Skip(16));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -51,4 +51,4 @@ namespace Kyoo.Authentication
|
|||||||
return user.Claims.FirstOrDefault(x => x.Type == "permissions")?.Value.Split(',');
|
return user.Claims.FirstOrDefault(x => x.Type == "permissions")?.Value.Split(',');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,4 +25,4 @@ namespace Kyoo.Authentication.Models.DTO
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public IFormFile Picture { get; set; }
|
public IFormFile Picture { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,4 +25,4 @@ namespace Kyoo.Authentication.Models.DTO
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string ReturnURL { get; set; }
|
public string ReturnURL { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,4 +15,4 @@ namespace Kyoo.Authentication.Models.DTO
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public bool StayLoggedIn { get; set; }
|
public bool StayLoggedIn { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -44,4 +44,4 @@ namespace Kyoo.Authentication.Models.DTO
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -100,4 +100,4 @@ namespace Kyoo.Authentication
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,4 +25,4 @@ namespace Kyoo.Authentication.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string ProfilePicturePath { get; set; }
|
public string ProfilePicturePath { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,4 +25,4 @@ namespace Kyoo.Authentication.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string Password { get; set; }
|
public string Password { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -20,4 +20,4 @@ namespace Kyoo.Authentication.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string[] NewUser { get; set; }
|
public string[] NewUser { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -223,4 +223,4 @@ namespace Kyoo.Authentication.Views
|
|||||||
return _options.Value.Permissions.Default ?? Array.Empty<string>();
|
return _options.Value.Permissions.Default ?? Array.Empty<string>();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -197,4 +197,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
return await CreateDirectory(path);
|
return await CreateDirectory(path);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -135,4 +135,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -138,4 +138,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -174,4 +174,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -140,4 +140,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -103,4 +103,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
await _database.SaveChangesAsync();
|
await _database.SaveChangesAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -62,4 +62,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
await _database.SaveChangesAsync();
|
await _database.SaveChangesAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -152,4 +152,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
return items;
|
return items;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -103,4 +103,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
await _database.SaveChangesAsync();
|
await _database.SaveChangesAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -313,4 +313,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
await Delete(resource);
|
await Delete(resource);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -209,4 +209,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
return roles;
|
return roles;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -78,4 +78,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
limit);
|
limit);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -196,4 +196,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
await _database.SaveChangesAsync();
|
await _database.SaveChangesAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -97,4 +97,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
await _database.SaveChangesAsync();
|
await _database.SaveChangesAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -62,4 +62,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
await _database.SaveChangesAsync();
|
await _database.SaveChangesAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -321,4 +321,4 @@ namespace Kyoo.Core.Controllers
|
|||||||
return _tasks.Select(x => x.Metadata).ToArray();
|
return _tasks.Select(x => x.Metadata).ToArray();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -156,4 +156,4 @@ namespace Kyoo.Core
|
|||||||
SA.New<IApplicationBuilder>(app => app.UseEndpoints(x => x.MapControllers()), SA.Endpoint)
|
SA.New<IApplicationBuilder>(app => app.UseEndpoints(x => x.MapControllers()), SA.Endpoint)
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -23,4 +23,4 @@ namespace Kyoo.Core
|
|||||||
return JsonConvert.DeserializeObject<T>(content);
|
return JsonConvert.DeserializeObject<T>(content);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -68,4 +68,4 @@ namespace Kyoo.Core.Models.Watch
|
|||||||
return SubtitleExtensions.ContainsKey(Path.GetExtension(filePath));
|
return SubtitleExtensions.ContainsKey(Path.GetExtension(filePath));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -55,4 +55,4 @@ namespace Kyoo.Core.Models.Options
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string MetadataPath { get; set; } = "metadata/";
|
public string MetadataPath { get; set; } = "metadata/";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -20,4 +20,4 @@ namespace Kyoo.Core.Models.Options
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string[] SubtitleRegex { get; set; }
|
public string[] SubtitleRegex { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,4 +25,4 @@ namespace Kyoo.Core.Models.Options
|
|||||||
[UsedImplicitly]
|
[UsedImplicitly]
|
||||||
public Dictionary<string, TimeSpan> Scheduled { get; set; } = new();
|
public Dictionary<string, TimeSpan> Scheduled { get; set; } = new();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -64,4 +64,4 @@ namespace Kyoo.Core.Models.Watch
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -117,4 +117,4 @@
|
|||||||
// return null;
|
// return null;
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
|
@ -82,4 +82,4 @@ namespace Kyoo.Core.Tasks
|
|||||||
progress.Report(100);
|
progress.Report(100);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -75,4 +75,4 @@ namespace Kyoo.Core.Tasks
|
|||||||
progress.Report(100);
|
progress.Report(100);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -60,4 +60,4 @@ namespace Kyoo.Core.Tasks
|
|||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -124,4 +124,4 @@
|
|||||||
// return null;
|
// return null;
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
|
@ -191,4 +191,4 @@ namespace Kyoo.Core.Tasks
|
|||||||
return await _libraryManager.CreateIfNotExists(item);
|
return await _libraryManager.CreateIfNotExists(item);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -81,4 +81,4 @@ namespace Kyoo.Core.Tasks
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -180,4 +180,4 @@ namespace Kyoo.Core.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,4 +77,4 @@ namespace Kyoo.Core.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,4 +77,4 @@ namespace Kyoo.Core.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -134,4 +134,4 @@ namespace Kyoo.Core.Api
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -203,4 +203,4 @@ namespace Kyoo.Core.Api
|
|||||||
return Ok();
|
return Ok();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -153,4 +153,4 @@ namespace Kyoo.Core.Api
|
|||||||
// Values are ignored and should not be editable, except if the internal value is set.
|
// Values are ignored and should not be editable, except if the internal value is set.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -105,4 +105,4 @@ namespace Kyoo.Core.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -56,4 +56,4 @@ namespace Kyoo.Core.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -105,4 +105,4 @@ namespace Kyoo.Core.Api
|
|||||||
return _files.FileResult(await _thumbs.GetImagePath(people, Images.Poster));
|
return _files.FileResult(await _thumbs.GetImagePath(people, Images.Poster));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -47,4 +47,4 @@ namespace Kyoo.Core.Api
|
|||||||
return _files.FileResult(await _thumbnails.GetImagePath(provider, Images.Logo));
|
return _files.FileResult(await _thumbnails.GetImagePath(provider, Images.Logo));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -86,4 +86,4 @@ namespace Kyoo.Core.Api
|
|||||||
return _libraryManager.Search<Studio>(query);
|
return _libraryManager.Search<Studio>(query);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,4 +77,4 @@ namespace Kyoo.Core.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -52,4 +52,4 @@ namespace Kyoo.Core.Api
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -33,4 +33,4 @@ namespace Kyoo.Database
|
|||||||
return config.GetValue<string>("database:enabled");
|
return config.GetValue<string>("database:enabled");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -180,4 +180,4 @@ namespace Kyoo.Postgresql.Migrations
|
|||||||
migrationBuilder.Sql(@"DROP VIEW library_items;");
|
migrationBuilder.Sql(@"DROP VIEW library_items;");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -166,4 +166,4 @@ namespace Kyoo.Postgresql
|
|||||||
return Expression.Lambda<Func<T, bool>>(call, query.Parameters);
|
return Expression.Lambda<Func<T, bool>>(call, query.Parameters);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -74,4 +74,4 @@ namespace Kyoo.Postgresql
|
|||||||
conn.ReloadTypes();
|
conn.ReloadTypes();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -182,4 +182,4 @@ namespace Kyoo.SqLite.Migrations
|
|||||||
migrationBuilder.Sql("DROP TRIGGER ShowSlugUpdate;");
|
migrationBuilder.Sql("DROP TRIGGER ShowSlugUpdate;");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -69,4 +69,4 @@ namespace Kyoo.SqLite
|
|||||||
context.Database.Migrate();
|
context.Database.Migrate();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,4 +77,4 @@ namespace Kyoo.TheMovieDb
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -44,4 +44,4 @@ namespace Kyoo.TheMovieDb
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -99,4 +99,4 @@ namespace Kyoo.TheMovieDb
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -42,4 +42,4 @@ namespace Kyoo.TheMovieDb
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -58,4 +58,4 @@ namespace Kyoo.TheTvdb
|
|||||||
builder.RegisterProvider<ProviderTvdb>();
|
builder.RegisterProvider<ProviderTvdb>();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -144,4 +144,4 @@ namespace Kyoo.TheTvdb
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,4 +15,4 @@ namespace Kyoo.TheTvdb.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string ApiKey { get; set; }
|
public string ApiKey { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -74,4 +74,4 @@ namespace Kyoo.Tests
|
|||||||
await Context.DisposeAsync();
|
await Context.DisposeAsync();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -190,4 +190,4 @@ namespace Kyoo.Tests
|
|||||||
Assert.Equal(0, await _repository.GetCount());
|
Assert.Equal(0, await _repository.GetCount());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -196,4 +196,4 @@ namespace Kyoo.Tests.Database
|
|||||||
KAssert.DeepEqual(value, ret.First());
|
KAssert.DeepEqual(value, ret.First());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -323,4 +323,4 @@ namespace Kyoo.Tests.Database
|
|||||||
KAssert.DeepEqual(value, ret.First());
|
KAssert.DeepEqual(value, ret.First());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user