rspec/rules/S3358/swift/compliant.adoc

14 lines
231 B
Plaintext
Raw Normal View History

[source,swift]
----
func getReadableStatus(job: Job) -> String {
let status: String;
if (job.isRunning) {
status = "Running";
}
else {
status = job.hasErrors ? "Failed" : "Succeeded";
}
return status;
}
----