Fixes intermine/intermine#289 and intermine/im-tables#81