Changed method to detect GAE