Add default empty value for pagespeedApiKey in settings
This commit is contained in:
1 parent
6268b2573c
commit
9b3085c84d
3 files changed
+5
-2
No files matched your search
+3
-1
@@ -53,7 +53,9 @@ function App() {
|
|||||||
const dispatch = useDispatch();
|
const dispatch = useDispatch();
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
dispatch(getAppSettings({ authToken }));
|
if (authToken) {
|
||||||
|
dispatch(getAppSettings({ authToken }));
|
||||||
|
}
|
||||||
}, [dispatch, authToken]);
|
}, [dispatch, authToken]);
|
||||||
|
|
||||||
// Cleanup
|
// Cleanup
|
||||||
|
|||||||
@@ -119,7 +119,7 @@ const AdvancedSettings = ({ isAdmin }) => {
|
|||||||
<Stack gap={theme.spacing(20)}>
|
<Stack gap={theme.spacing(20)}>
|
||||||
<Field
|
<Field
|
||||||
id="apiBaseUrl"
|
id="apiBaseUrl"
|
||||||
label="Client Host"
|
label="API URL Host"
|
||||||
value={localSettings.apiBaseUrl}
|
value={localSettings.apiBaseUrl}
|
||||||
onChange={handleChange}
|
onChange={handleChange}
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -48,6 +48,7 @@ const AppSettingsSchema = mongoose.Schema(
|
|||||||
},
|
},
|
||||||
pagespeedApiKey: {
|
pagespeedApiKey: {
|
||||||
type: String,
|
type: String,
|
||||||
|
default: "",
|
||||||
},
|
},
|
||||||
systemEmailHost: {
|
systemEmailHost: {
|
||||||
type: String,
|
type: String,
|
||||||
|
|||||||
Reference in new issue
Block a user