Fix empty code query