Adding headers when needed