Use C# 10 string interpolation wherever possible

This commit is contained in:
Archi
2021-11-11 01:53:34 +01:00
parent 60376c4d93
commit d1fc7ebb74
20 changed files with 76 additions and 73 deletions

View File

@@ -55,7 +55,7 @@ public sealed class StructureController : ArchiController {
try {
obj = Activator.CreateInstance(targetType, true);
} catch (Exception e) {
return BadRequest(new GenericResponse(false, string.Format(CultureInfo.CurrentCulture, Strings.ErrorParsingObject, nameof(targetType)) + Environment.NewLine + e));
return BadRequest(new GenericResponse(false, $"{string.Format(CultureInfo.CurrentCulture, Strings.ErrorParsingObject, nameof(targetType))}{Environment.NewLine}{e}"));
}
return Ok(new GenericResponse<object>(obj));