Nested if can be replaced with else if CRT-A0011
Anti-pattern
Major
1 occurrence in this check
can replace 'else {if cond {}}' with 'else if cond {}'
345		if err = ctxRepo.UploadAvatar(data); err != nil {
346			return fmt.Errorf("upload avatar: %v", err)
347		}
348	} else {349		// No avatar is uploaded and reset setting back.
350		if !com.IsFile(ctxRepo.CustomAvatarPath()) {
351			ctxRepo.UseCustomAvatar = false