mirror of
https://github.com/bitwarden/directory-connector
synced 2025-12-05 23:53:21 +00:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3d374fc792 | ||
|
|
b51c842d18 | ||
|
|
95b595d5bf | ||
|
|
445c3f220a | ||
|
|
9644d95b9b |
@@ -132,27 +132,25 @@ export class DashboardComponent implements OnInit, OnDestroy {
|
||||
}
|
||||
}
|
||||
|
||||
if (userMap.size > 0) {
|
||||
this.sort(this.simGroups);
|
||||
for (const g of this.simGroups) {
|
||||
if (g.userMemberExternalIds == null) {
|
||||
continue;
|
||||
}
|
||||
this.sort(this.simGroups);
|
||||
for (const g of this.simGroups) {
|
||||
if (g.userMemberExternalIds == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
for (const uid of g.userMemberExternalIds) {
|
||||
if (userMap.has(uid)) {
|
||||
if ((g as any).users == null) {
|
||||
(g as any).users = [];
|
||||
}
|
||||
(g as any).users.push(userMap.get(uid));
|
||||
}
|
||||
}
|
||||
|
||||
if ((g as any).users != null) {
|
||||
this.sort((g as any).users);
|
||||
const anyG = (g as any);
|
||||
anyG.users = [];
|
||||
for (const uid of g.userMemberExternalIds) {
|
||||
if (userMap.has(uid)) {
|
||||
anyG.users.push(userMap.get(uid));
|
||||
} else {
|
||||
anyG.users.push({ displayName: uid });
|
||||
}
|
||||
}
|
||||
|
||||
this.sort(anyG.users);
|
||||
}
|
||||
|
||||
resolve();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -56,10 +56,12 @@ export class Main {
|
||||
this.menuMain = new MenuMain(this);
|
||||
this.updaterMain = new UpdaterMain(this.i18nService, this.windowMain, 'directory-connector', () => {
|
||||
this.messagingService.send('checkingForUpdate');
|
||||
}, null, () => {
|
||||
}, () => {
|
||||
this.messagingService.send('doneCheckingForUpdate');
|
||||
}, () => {
|
||||
this.messagingService.send('doneCheckingForUpdate');
|
||||
});
|
||||
this.trayMain = new TrayMain(this.windowMain, this.i18nService, this.storageService,);
|
||||
this.trayMain = new TrayMain(this.windowMain, this.i18nService, this.storageService);
|
||||
this.messagingMain = new MessagingMain(this.windowMain, this.menuMain, this.updaterMain, this.trayMain);
|
||||
this.messagingService = new ElectronMainMessagingService(this.windowMain, (message) => {
|
||||
this.messagingMain.onMessage(message);
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"name": "bitwarden-directory-connector",
|
||||
"productName": "Bitwarden Directory Connector",
|
||||
"description": "Sync your user directory to your Bitwarden organization.",
|
||||
"version": "2.0.0",
|
||||
"version": "2.0.1",
|
||||
"author": "8bit Solutions LLC <hello@bitwarden.com> (https://bitwarden.com)",
|
||||
"homepage": "https://bitwarden.com",
|
||||
"license": "GPL-3.0",
|
||||
|
||||
@@ -60,7 +60,7 @@ export class SyncService {
|
||||
this.flattenUsersToGroups(groups, groups);
|
||||
}
|
||||
|
||||
if (test || groups == null || groups.length === 0 || users == null || users.length === 0) {
|
||||
if (test || ((groups == null || groups.length === 0) && (users == null || users.length === 0))) {
|
||||
if (!test) {
|
||||
await this.saveSyncTimes(syncConfig, now);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user