added route and controller for avatar

王权利请求将github/fork/Popl7/avatar_routes_added合并到master

Created by: Popl7

as a fix for issue #5430 I have added the suggested controller and route.

合并请求报告