fix scoped method bug