Cleaned up code to match with required Redis coding style