Fix npe when method is a lambda
Merge pull request #13 from CodeHex/fix-npe

Fix npe when method is a lambda