Redis commands implemented in javascript (learning purpose only)