Migrate wekan-ldap to async API for Meteor 3.0

- Replace Meteor.wrapAsync with native Promises
- Convert all sync methods to async
- Use async DB operations (findOneAsync, updateAsync)
- Bump version 0.0.2 → 0.1.0
This commit is contained in:
Harry Adel 2026-01-29 19:58:23 +02:00
parent eb0c9ac1e6
commit 7d56dca80b
6 changed files with 102 additions and 83 deletions

View file

@ -2,7 +2,7 @@ import {importNewUsers} from './sync';
import LDAP from './ldap';
Meteor.methods({
ldap_sync_now() {
async ldap_sync_now() {
const user = Meteor.user();
if (!user) {
throw new Meteor.Error('error-invalid-user', 'Invalid user', { method: 'ldap_sync_users' });
@ -18,7 +18,7 @@ Meteor.methods({
this.unblock();
importNewUsers();
await importNewUsers();
return {
message: 'Sync_in_progress',