refactoring, add options hash to client_data