Fixed 'none' profile
This commit is contained in:
parent
960923de40
commit
fc5ef5da5a
2 changed files with 4 additions and 2 deletions
|
|
@ -6,7 +6,10 @@ const DebugSettings = ({ type, title, ip, profile, setProfile }) => {
|
|||
const [value, setValue] = useState('')
|
||||
|
||||
useEffect(() => {
|
||||
if (profile === 'match') {
|
||||
if (profile === 'none') {
|
||||
setValue('')
|
||||
chrome.storage.sync.set({ [type]: '' })
|
||||
} else if (profile === 'match') {
|
||||
if (ip) {
|
||||
const ipTypeValue =
|
||||
type === 'locale' ? countryLocales[ip.countryCode].locale : ip[type]
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
const profiles = {
|
||||
none: { timezone: '', locale: '', lat: '', lon: '' },
|
||||
baghdad: {
|
||||
name: 'Baghdad',
|
||||
timezone: 'Asia/Baghdad',
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue