Ensure I validate before attempting to update password for reset password flow. Send some validation issues back to FE.
This commit is contained in:
parent
52b91a9b92
commit
983078de02
3 changed files with 30 additions and 9 deletions
|
|
@ -31,13 +31,10 @@ namespace API.Services
|
|||
|
||||
public void EnsureCacheDirectory()
|
||||
{
|
||||
// TODO: Replace with DirectoryService.ExistOrCreate()
|
||||
_logger.LogDebug("Checking if valid Cache directory: {CacheDirectory}", CacheDirectory);
|
||||
var di = new DirectoryInfo(CacheDirectory);
|
||||
if (!di.Exists)
|
||||
if (_directoryService.ExistOrCreate(CacheDirectory))
|
||||
{
|
||||
_logger.LogError("Cache directory {CacheDirectory} is not accessible or does not exist. Creating...", CacheDirectory);
|
||||
Directory.CreateDirectory(CacheDirectory);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue