Common API JS fix for persistent callbacks