Implement separate state for server and app settings

This commit is contained in:
Wesley van der Sanden
2017-10-21 21:31:01 +02:00
parent fc28f4e02b
commit 3883aba9fb
2 changed files with 42 additions and 33 deletions

View File

@@ -21,11 +21,8 @@ function getClassNameAndMessage(savingState, errorMessage) {
}
function AutoSaveIndicator(props) {
const {show, savingState, errorMessage, ...rest} = props;
const {savingState, errorMessage, ...rest} = props;
const {className, message} = getClassNameAndMessage(savingState, errorMessage);
if (!show) {
return null;
}
return (
<Alert
@@ -39,7 +36,6 @@ function AutoSaveIndicator(props) {
}
AutoSaveIndicator.propTypes = {
show: PropTypes.bool,
savingState: PropTypes.string.isRequired,
errorMessage: PropTypes.string
};