Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Regression: cannot extend headers in requestTransform fn #11438

Closed
@Narretz

Description

@Narretz

Before 5da1256, it used to be possible to do this:

        function requestTransform(data, headers) {
            headers = angular.extend(headers(), {
              'X-MY_HEADER': 'abcd'
            });
          }
          return angular.isObject(data) ? angular.toJson(data) : data;
        }

This is because the headersGetter used to re-use the argument instead of declaring a new one: 5da1256#diff-748e0a1e1a7db3458d5f95d59d7e16c9L71

/cc @pkozlowski-opensource

Metadata

Metadata

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions