Add icons option to the directory middleware