TS: fixed onlySpecifiedMethods not taking emptyGeneratorMethods into account.