fix queryCommands