Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Z
zimbra-admin-api-js
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Public
zimbra-admin-api-js
Commits
d7e9b763
Commit
d7e9b763
authored
Apr 27, 2016
by
Patricio Bruna
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test parseResponse with error null
parent
49e8aeed
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
4 deletions
+4
-4
zimbra-admin-api.js
lib/zimbra-admin-api.js
+1
-1
zimbra-admin-api.js.map
lib/zimbra-admin-api.js.map
+1
-1
index.js
src/index.js
+1
-1
test.js
test/js/spec/test.js
+1
-1
No files found.
lib/zimbra-admin-api.js
View file @
d7e9b763
...
@@ -286,7 +286,7 @@ return /******/ (function(modules) { // webpackBootstrap
...
@@ -286,7 +286,7 @@ return /******/ (function(modules) { // webpackBootstrap
var response_name = that.dictionary.resourceResponseName(resource);
var response_name = that.dictionary.resourceResponseName(resource);
var response_object = data.get()[request_data.response_name][response_name][0];
var response_object = data.get()[request_data.response_name][response_name][0];
var result = that.dictionary.classFactory(resource, response_object, that);
var result = that.dictionary.classFactory(resource, response_object, that);
return callback(
true
, result);
return callback(
null
, result);
}
}
// For requests that returns empty Object when Success
// For requests that returns empty Object when Success
lib/zimbra-admin-api.js.map
View file @
d7e9b763
This diff is collapsed.
Click to expand it.
src/index.js
View file @
d7e9b763
...
@@ -177,7 +177,7 @@ export default class ZimbraAdminApi {
...
@@ -177,7 +177,7 @@ export default class ZimbraAdminApi {
const
response_name
=
that
.
dictionary
.
resourceResponseName
(
resource
);
const
response_name
=
that
.
dictionary
.
resourceResponseName
(
resource
);
const
response_object
=
data
.
get
()[
request_data
.
response_name
][
response_name
][
0
];
const
response_object
=
data
.
get
()[
request_data
.
response_name
][
response_name
][
0
];
const
result
=
that
.
dictionary
.
classFactory
(
resource
,
response_object
,
that
);
const
result
=
that
.
dictionary
.
classFactory
(
resource
,
response_object
,
that
);
return
callback
(
true
,
result
);
return
callback
(
null
,
result
);
}
}
// For requests that returns empty Object when Success
// For requests that returns empty Object when Success
...
...
test/js/spec/test.js
View file @
d7e9b763
...
@@ -50,7 +50,6 @@
...
@@ -50,7 +50,6 @@
let
api
=
new
ZimbraAdminApi
(
auth_data
);
let
api
=
new
ZimbraAdminApi
(
auth_data
);
let
callback
=
function
(
err
,
response
)
{
let
callback
=
function
(
err
,
response
)
{
if
(
err
)
return
console
.
error
(
err
);
if
(
err
)
return
console
.
error
(
err
);
console
.
log
(
api
.
client
);
expect
(
api
.
client
.
token
).
to
.
exist
;
expect
(
api
.
client
.
token
).
to
.
exist
;
done
();
done
();
};
};
...
@@ -134,6 +133,7 @@
...
@@ -134,6 +133,7 @@
let
callback
=
function
(
err
,
data
){
let
callback
=
function
(
err
,
data
){
let
domain_id
=
data
.
id
;
let
domain_id
=
data
.
id
;
api
.
getDomain
(
domain_id
,
function
(
err
,
data
){
api
.
getDomain
(
domain_id
,
function
(
err
,
data
){
if
(
err
)
return
console
.
error
(
err
);
expect
(
data
.
name
).
to
.
equal
(
'zboxapp.dev'
);
expect
(
data
.
name
).
to
.
equal
(
'zboxapp.dev'
);
done
();
done
();
});
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment