Implementation of File Exists Function; Delete FileInfos upon Permanent User Delete (#8958)
Check if file was deleted on FS Warning message if file couldnt be removed
Этот коммит содержится в:
коммит произвёл
Harrison Healey
родитель
fc158fce90
Коммит
ecefa6cdd1
@@ -70,6 +70,14 @@ func (a *App) ReadFile(path string) ([]byte, *model.AppError) {
|
||||
return backend.ReadFile(path)
|
||||
}
|
||||
|
||||
func (a *App) FileExists(path string) (bool, *model.AppError) {
|
||||
backend, err := a.FileBackend()
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
return backend.FileExists(path)
|
||||
}
|
||||
|
||||
func (a *App) MoveFile(oldPath, newPath string) *model.AppError {
|
||||
backend, err := a.FileBackend()
|
||||
if err != nil {
|
||||
|
||||
Ссылка в новой задаче
Block a user