fix: shareSmbEnabled failing when using active directory

This commit is contained in:
Alexis Tyler
2021-01-15 11:31:09 +10:30
parent 67198583aa
commit d99abde5cd
2 changed files with 5 additions and 1 deletions
+2 -1
View File
@@ -252,7 +252,8 @@ const parse = (state: VarIni): Var => {
shareNfsCount: toNumber(state.shareNfsCount),
shareNfsEnabled: iniBooleanToJsBoolean(state.shareNfsEnabled),
shareSmbCount: toNumber(state.shareSmbCount),
shareSmbEnabled: iniBooleanToJsBoolean(state.shareSmbEnabled),
shareSmbEnabled: ['yes', 'ads'].includes(state.shareSmbEnabled),
shareSmbMode: state.shareSmbEnabled === 'ads' ? 'active-directory' : 'workgroup',
shutdownTimeout: toNumber(state.shutdownTimeout),
spindownDelay: toNumber(state.spindownDelay),
spinupGroups: iniBooleanToJsBoolean(state.spinupGroups),
+3
View File
@@ -158,7 +158,10 @@ export interface Var {
shareNfsEnabled: boolean;
/** Total number of SMB shares. */
shareSmbCount: number;
/** Is smb enabled */
shareSmbEnabled: boolean;
/** Which mode is smb running in? active-directory | workgroup */
shareSmbMode: string;
shareUser: string;
// shareUserExclude
shutdownTimeout: number;