Simplified the code to retrieve a particular method.