fixed a bug that some query result treat as unsafe context