Changed entity to ws_entity