Workaround infinite loop issue