Fix bug in tplcache.

1. bug of nil tplcache object when call `ReplaceCachedTemplates` before
server start. caused by wrong initialization order.
2. only handle default static dir "assets" when it exists before sever
start.
Remove some garbage lines.
Fix import but not used error.
Move some initialization steps to init function.
Fix a bug in mux.

1. the bug will cause crash in calling mux match method, though the crash
will be recovered.
Merge pull request #13 from ggicci/dev

Dev