Localization - Part 2 (#2178)
* Changed language codes in the UI to be a list of all codes we will ever support. * Converted actionables * Fixed the GetLocales not using Intersect, but Union. * Fixed some localization strings in backend when user doesn't exist. Removed AllowAnonymous from reset-password, since it is a protected API * Fixed all instances of anonymous APIs where Claim wouldn't work * Keyed preference options and mixed misc localization issues * Translations update from Hosted Weblate (#2177) * Bump versions by dotnet-bump-version. * Added translation using Weblate (Dutch) * Bump versions by dotnet-bump-version. * Translated using Weblate (Dutch) Currently translated at 20.8% (33 of 158 strings) Translation: Kavita/backend Translate-URL: https://hosted.weblate.org/projects/kavita/backend/nl/ * Translated using Weblate (Spanish) Currently translated at 1.4% (20 of 1371 strings) Translation: Kavita/ui Translate-URL: https://hosted.weblate.org/projects/kavita/ui/es/ * Translated using Weblate (Dutch) Currently translated at 60.1% (95 of 158 strings) Translation: Kavita/backend Translate-URL: https://hosted.weblate.org/projects/kavita/backend/nl/ * Translated using Weblate (Dutch) Currently translated at 60.1% (95 of 158 strings) Translation: Kavita/backend Translate-URL: https://hosted.weblate.org/projects/kavita/backend/nl/ * Added translation using Weblate (Dutch) --------- Co-authored-by: Hans Kalisvaart <hans.kalisvaart@gmail.com> Co-authored-by: Javier Barbero <javier.agustin.barbero@gmail.com> Co-authored-by: Stijn <stijn.biemans@gmail.com> --------- Co-authored-by: Weblate (bot) <hosted@weblate.org> Co-authored-by: Hans Kalisvaart <hans.kalisvaart@gmail.com> Co-authored-by: Javier Barbero <javier.agustin.barbero@gmail.com> Co-authored-by: Stijn <stijn.biemans@gmail.com>
This commit is contained in:
parent
c7701bc729
commit
69532d45ac
26 changed files with 2035 additions and 195 deletions
|
|
@ -279,7 +279,7 @@ public class LibraryController : BaseApiController
|
|||
var isAdmin = await _unitOfWork.UserRepository.IsUserAdminAsync(user);
|
||||
if (!isAdmin) return BadRequest("API key must belong to an admin");
|
||||
|
||||
if (dto.FolderPath.Contains("..")) return BadRequest(await _localizationService.Translate(User.GetUserId(), "invalid-path"));
|
||||
if (dto.FolderPath.Contains("..")) return BadRequest(await _localizationService.Translate(user.Id, "invalid-path"));
|
||||
|
||||
dto.FolderPath = Services.Tasks.Scanner.Parser.Parser.NormalizePath(dto.FolderPath);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue