Fixes of method count calculation