fix profile bug #349