Add custom expiration to getQuery()