Skip to content
Snippets Groups Projects
Commit ad96de12 authored by Thorge Petersen's avatar Thorge Petersen
Browse files

Fixed mimetype for robots.txt

parent 43f454f3
Branches
Tags
1 merge request!41Version 2.0.0
import ckan.plugins.toolkit as toolkit
from flask import Blueprint
import ckan.lib.base as base
from flask import Blueprint, make_response
import logging
log = logging.getLogger(__name__)
......@@ -20,4 +21,6 @@ def not_found():
def robots_txt():
log.info("views.default::robots_txt")
return toolkit.render(u'robots.txt')
resp = make_response(base.render('home/robots.txt'))
resp.headers['Content-Type'] = "text/plain; charset=utf-8"
return resp
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment