Skip to content

Commit e211ac4

Browse files
authored
Merge pull request #53 from moneytree/AKL-656
[AKL-656] fix for Safari 14 issue
2 parents 02fcb53 + 9fb69d0 commit e211ac4

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/api/__tests__/authorize.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ describe('api', () => {
6868
configs: generateConfigs(),
6969
});
7070
const url = `${MY_ACCOUNT_DOMAINS.production}/oauth/authorize?${query}`;
71-
expect(open).toBeCalledWith(url, '_self');
71+
expect(open).toBeCalledWith(url, '_self', 'noreferrer');
7272
});
7373

7474
test('with options', () => {
@@ -101,7 +101,7 @@ describe('api', () => {
101101
configs: generateConfigs(),
102102
});
103103
const url = `${MY_ACCOUNT_DOMAINS.production}/oauth/authorize?${query}`;
104-
expect(open).toBeCalledWith(url, '_self');
104+
expect(open).toBeCalledWith(url, '_self', 'noreferrer');
105105
});
106106

107107
test('without window', () => {

src/api/authorize.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ export default function authorize(
7070

7171
window.open(
7272
`${MY_ACCOUNT_DOMAINS[mode]}/oauth/authorize?${queryString}`,
73-
getIsTabValue(isNewTab)
73+
getIsTabValue(isNewTab),
74+
'noreferrer'
7475
);
7576
}

0 commit comments

Comments
 (0)