function declarations fixed