Removed: use credis (depreciated)
Fixed: moved code inside maion function