Fixing curl generation when nil header is passed