Skip to content

Commit

Permalink
MWPW-147594: Consumers mappings for origin not being sent when using …
Browse files Browse the repository at this point in the history
…sidekick (#2244)

* Fix for origin always being upper cased

* Update tools/send-to-caas/send-utils.js

changing to const

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Okan Sahin <39759830+mokimo@users.noreply.github.com>
  • Loading branch information
3 people authored May 14, 2024
1 parent 7a613d0 commit b617478
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tools/send-to-caas/send-utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -193,8 +193,9 @@ const getOrigin = (fgColor) => {
cc: 'hawks',
dc: 'doccloud',
};
if (mappings[origin] || origin) {
return mappings[origin] || origin;
const originLC = (mappings[origin] || origin).toLowerCase();
if (originLC) {
return originLC;

Check warning on line 198 in tools/send-to-caas/send-utils.js

View check run for this annotation

Codecov / codecov/patch

tools/send-to-caas/send-utils.js#L196-L198

Added lines #L196 - L198 were not covered by tests
}

if (window.location.hostname.endsWith('.hlx.page')) {
Expand Down

0 comments on commit b617478

Please sign in to comment.