fix profile reading