pulled the if out and used do.call for the methods"