fixed bug when defaultHeaders were overwritten