Skip to content

Commit 276eba3

Browse files
authored
fix: Remove hard coded locale
2 parents 89c6802 + da4bb4b commit 276eba3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/WebView.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const defaultProps = {
2222
cwCookie: '',
2323
user: {},
2424
locale: 'en',
25-
customattributes: {},
25+
customAttributes: {},
2626
};
2727

2828
const WebViewComponent = ({
@@ -34,7 +34,7 @@ const WebViewComponent = ({
3434
customAttributes,
3535
closeModal,
3636
}) => {
37-
let widgetUrl = `${baseUrl}/widget?website_token=${websiteToken}&locale=en`;
37+
let widgetUrl = `${baseUrl}/widget?website_token=${websiteToken}&locale=${locale}`;
3838

3939
if (cwCookie) {
4040
widgetUrl = `${widgetUrl}&cw_conversation=${cwCookie}`;
@@ -87,7 +87,7 @@ const styles = StyleSheet.create({
8787
},
8888
webViewContainer: {
8989
flex: 1,
90-
}
90+
},
9191
});
9292
WebViewComponent.defaultProps = defaultProps;
9393
WebViewComponent.propTypes = propTypes;

0 commit comments

Comments
 (0)