Adding compatibility for both node 10 and node 11