fix waiting for wrong session variable