fix getInstance / getWeakInstance