Added formatting and fixed a profile bug