mirror of
https://github.com/owncast/owncast.git
synced 2025-11-01 10:55:57 +08:00
ts cleanup on some config components
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
// TODO: add a notication after updating info that changes will take place either on a new stream or server restart. may be different for each field.
|
||||
|
||||
import React, { useState, useEffect } from 'react';
|
||||
import PropTypes, { any } from 'prop-types';
|
||||
import PropTypes from 'prop-types';
|
||||
|
||||
import { STATUS, fetchData, FETCH_INTERVAL, SERVER_CONFIG } from './apis';
|
||||
import { ConfigDetails, UpdateArgs } from '../types/config-section';
|
||||
@ -50,7 +50,7 @@ export const ServerStatusContext = React.createContext({
|
||||
...initialServerStatusState,
|
||||
serverConfig: initialServerConfigState,
|
||||
|
||||
setFieldInConfigState: any,
|
||||
setFieldInConfigState: (args: UpdateArgs) => { return args },
|
||||
});
|
||||
|
||||
const ServerStatusProvider = ({ children }) => {
|
||||
@ -88,7 +88,6 @@ const ServerStatusProvider = ({ children }) => {
|
||||
...config,
|
||||
[fieldName]: value,
|
||||
};
|
||||
console.log({updatedConfig, fieldName, value, path})
|
||||
setConfig(updatedConfig);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user