Copied https://github.com/projecthydra/sufia/commit/f9760a2e1905929e7b13...

...0a7319ef65f9d247f542 to fix https://github.com/projecthydra/sufia/issues/367.