modified to support imports