diff --git a/cli.js b/cli.js
index <HASH>..<HASH> 100755
--- a/cli.js
+++ b/cli.js
@@ -52,10 +52,16 @@ function runFastify (opts) {
     return module.exports.stop(e)
   }
 
-  if (file.length !== 3) {
+  console.log(file.constructor.name)
+
+  if (file.length !== 3 && file.constructor.name === 'Function') {
     return module.exports.stop(new Error('Plugin function should contain 3 arguments. Refer to ' +
                     'documentation for more information.'))
   }
+  if (file.length !== 2 && file.constructor.name === 'AsyncFunction') {
+    return module.exports.stop(new Error('Async/Await plugin function should contain 2 arguments.' +
+    'Refer to documentation for more information.'))
+  }
 
   const options = {
     logger: {
Rewrote the arity check upon the plugin signature to support async/await plugins