private RunResult RunEngine(InputModel inputModel) { RunResult result = null; try { var wordSequence = engine.Run(inputModel, WordLength); logger.LogInformation("Successfully generated result file"); result = RunResult.Success(wordSequence); } catch (Exception ex) { result = RunResult.Failure(ex.Message); logger.LogError($"Unexpected error. Message: {ex.Message}"); } return(result); }