fixed main loading