More protobufjs migration
This commit is contained in:
parent
cf06e6638e
commit
ddbbe3a6b1
70 changed files with 3967 additions and 3369 deletions
|
@ -2,7 +2,9 @@
|
|||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
import { LocalizerType } from '../types/Util';
|
||||
import { AccessControlClass } from '../textsecure.d';
|
||||
import { SignalService as Proto } from '../protobuf';
|
||||
|
||||
const AccessControlEnum = Proto.AccessControl.AccessRequired;
|
||||
|
||||
type AccessControlOption = {
|
||||
text: string;
|
||||
|
@ -10,17 +12,16 @@ type AccessControlOption = {
|
|||
};
|
||||
|
||||
export function getAccessControlOptions(
|
||||
accessEnum: typeof AccessControlClass.AccessRequired,
|
||||
i18n: LocalizerType
|
||||
): Array<AccessControlOption> {
|
||||
return [
|
||||
{
|
||||
text: i18n('GroupV2--all-members'),
|
||||
value: accessEnum.MEMBER,
|
||||
value: AccessControlEnum.MEMBER,
|
||||
},
|
||||
{
|
||||
text: i18n('GroupV2--only-admins'),
|
||||
value: accessEnum.ADMINISTRATOR,
|
||||
value: AccessControlEnum.ADMINISTRATOR,
|
||||
},
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue