Fixed 'none' profile

This commit is contained in:
z0ccc 2022-05-12 20:14:41 -04:00
parent 7ba33fb6c6
commit 247e4edfe7
2 changed files with 4 additions and 2 deletions

View file

@ -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]

View file

@ -1,5 +1,4 @@
const profiles = {
none: { timezone: '', locale: '', lat: '', lon: '' },
baghdad: {
name: 'Baghdad',
timezone: 'Asia/Baghdad',