Skip to content

Commit

Permalink
Merge pull request #33 from channelcat/middleware-unreachable
Browse files Browse the repository at this point in the history
Middleware unreachable
  • Loading branch information
channelcat authored Oct 16, 2016
2 parents e6fb52c + 516f661 commit 8e07edb
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
4 changes: 0 additions & 4 deletions sanic/middleware.py

This file was deleted.

7 changes: 0 additions & 7 deletions sanic/sanic.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
import asyncio
from inspect import isawaitable
from traceback import format_exc
from types import FunctionType

from .config import Config
from .exceptions import Handler
from .log import log, logging
from .middleware import Middleware
from .response import HTTPResponse
from .router import Router
from .server import serve
Expand Down Expand Up @@ -80,11 +78,6 @@ def register_middleware(middleware):
attach_to = args[0]
return register_middleware

if isinstance(middleware, FunctionType):
middleware = Middleware(process_request=middleware)

return middleware

# -------------------------------------------------------------------- #
# Request Handling
# -------------------------------------------------------------------- #
Expand Down

0 comments on commit 8e07edb

Please sign in to comment.