fix parsing of imports