Fixed transform_url function in WikiAccessMiddleware.

In the current implementation if the path prefix contains the
wiki_path value it gets deleted. For example if the prefix is
'/courses/edx/math101/2014' and wiki_path is '101/' the final
prefix becomes '/courses/edx/math2014'.

LMS-2556
Merge pull request #3476 from edx/usman/lms2556-wiki-urls

Fixed transform_url function in WikiAccessMiddleware.