fixing bugs in header