Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@existdb/node-exist

Package Overview
Dependencies
Maintainers
3
Versions
47
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@existdb/node-exist - npm Package Compare versions

Comparing version
4.3.1
to
4.3.2
+1
-1
components/users.js
function getUserInfo (client, userName) {
return client.promisedMethodCall('getUser', [userName])
return client.promisedMethodCall('getAccount', [userName])
}

@@ -4,0 +4,0 @@

@@ -58,3 +58,3 @@ {

},
"version": "4.3.1"
"version": "4.3.2"
}

@@ -18,13 +18,39 @@ const test = require('tape')

test.skip('get user info', function (t) {
test('get user info for admin', function (t) {
const db = connect(connectionOptions)
db.users.byName('admin')
db.users.getUserInfo('admin')
.then(function (info) {
console.log(info)
t.ok(info)
t.end()
})
.catch(function (e) {
console.error(e)
t.fail()
t.end()
})
})
test('get user info for guest', function (t) {
const db = connect(connectionOptions)
db.users.getUserInfo('guest')
.then(function (info) {
t.ok(info)
t.end()
})
.catch(function (e) {
t.fail()
t.end()
})
})
test('get user info for non-existent user', function (t) {
const db = connect(connectionOptions)
db.users.getUserInfo('thisuserschouldnotexist')
.then(function (info) {
t.fail()
t.end()
})
.catch(function (e) {
t.ok(e)
t.end()
})
})