fixing file-loading issues