fix login, fix image preload