apply patch from https://github.com/graphite-project/graphite-web/pull/329