Bug fix+new functionality

Added support for methods inside Class-based.
Fixed middleware-->Middleware typo.