That sounds like a separate issue (now fixed) - and doesn't make any sense with regards to the change above.
As it stands The refresh will be called before the call to delete the queries is complete.