Removing unnecessary constructor
This commit is contained in:
parent
03ef9b2203
commit
d3a0746ebb
@ -22,12 +22,8 @@ const localeToAvailable = (locale, available, defaultLocale) => {
|
||||
};
|
||||
|
||||
class LocaleSwitcher extends React.PureComponent {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.state = {
|
||||
state = {
|
||||
current: localeToAvailable(i18n.language || '', Object.keys(locales), 'en')
|
||||
};
|
||||
}
|
||||
|
||||
localeSelector = React.createRef()
|
||||
|
Loading…
Reference in New Issue
Block a user