fix issue with openCallback with noDeclare option