refactored queen