earl-grey
earl-grey copied to clipboard
Embedded shorthand pattern match doesn't work in async functions
For example, this fails with Illegal clause
error:
async manual-install = (match) ->
"Nginx" -> await nginx-setup.manual-details()
"Apache" -> await apache-setup.manual-details()
But the longhand works fine:
async manual-install = (type) ->
match type:
"Nginx" -> await nginx-setup.manual-details()
"Apache" -> await apache-setup.manual-details()