Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

node-gitlab-api

Package Overview
Dependencies
Maintainers
1
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-gitlab-api - npm Package Compare versions

Comparing version 2.0.0-rc.1 to 2.0.0-rc.2

2

package.json
{
"name": "node-gitlab-api",
"version": "2.0.0-rc.1",
"version": "2.0.0-rc.2",
"description": "Full NodeJS implementation of the GitLab API. Supports Promises, Async/Await.",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -18,2 +18,3 @@ [![dependencies Status](https://david-dm.org/jdalrymple/node-gitlab-api/status.svg)](https://david-dm.org/jdalrymple/node-gitlab-api)[![devDependencies Status](https://david-dm.org/jdalrymple/node-gitlab-api/dev-status.svg)](https://david-dm.org/jdalrymple/node-gitlab-api?type=dev)[![Code Climate](https://codeclimate.com/github/jdalrymple/node-gitlab-api/badges/gpa.svg)](https://codeclimate.com/github/jdalrymple/node-gitlab-api)[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

* [Projects](https://github.com/jdalrymple/node-gitlab-api/blob/master/docs/projects.md)
* [Groups](https://github.com/jdalrymple/node-gitlab-api/blob/master/docs/groups.md)
* [Contributors](#contributors)

@@ -106,2 +107,3 @@ * [License](#licence)

* [Projects](https://github.com/jdalrymple/node-gitlab-api/blob/master/docs/projects.md)
* [Groups](https://github.com/jdalrymple/node-gitlab-api/blob/master/docs/groups.md)

@@ -135,3 +137,3 @@ ## Contributors

- Renaming addKey just to add in UserKeys class
- Renaming deploy_keys and merge_requests to deployKeys and mergeRequests for consistancy
- Renaming deploy_keys and merge_requests to deployKeys and mergeRequests for consistency
- Adding Project Access Requests

@@ -138,0 +140,0 @@ - Removing old group member functions from the groups class as they have been moved to the GroupMembers class. This includes the addMember, listMembers, editMember, and removeMember. These functions can now be access via group.members.add, group.members.all, group.members.edit and group.members.remove respectively.

const LinkParser = require('parse-link-header');
async function getAllPages(client, endpoint, options = {}, results = []) {
async function getAllPages(client, endpoint, options, results = []) {
const response = await client.get(endpoint, options, true);

@@ -26,3 +26,3 @@

get(endpoint, options) {
get(endpoint, options = {}) {
if (!options.page) {

@@ -35,15 +35,15 @@ return getAllPages(this.client, endpoint, options);

post(endpoint, options) {
post(endpoint, options = {}) {
return this.client.post(endpoint, options);
}
postForm(endpoint, options) {
postForm(endpoint, options = {}) {
return this.client.postForm(endpoint, options);
}
put(endpoint, options) {
put(endpoint, options = {}) {
return this.client.put(endpoint, options);
}
delete(endpoint, options) {
delete(endpoint, options = {}) {
return this.client.delete(endpoint, options);

@@ -50,0 +50,0 @@ }

@@ -17,6 +17,6 @@ const BaseModel = require('./BaseModel');

protect(projectId, branchName, options = {}) {
protect(projectId, branchId, options = {}) {
const pId = Utils.parse(projectId);
return this.put(`projects/${pId}/repository/branches/${encodeURI(branchName)}/protect`, options);
return this.put(`projects/${pId}/repository/branches/${encodeURI(branchId)}/protect`, options);
}

@@ -30,12 +30,12 @@

show(projectId, branchName) {
show(projectId, branchId) {
const pId = Utils.parse(projectId);
return this.get(`projects/${pId}/repository/branches/${encodeURI(branchName)}`);
return this.get(`projects/${pId}/repository/branches/${encodeURI(branchId)}`);
}
unprotect(projectId, branchName) {
unprotect(projectId, branchId) {
const pId = Utils.parse(projectId);
return this.put(`projects/${pId}/repository/branches/${encodeURI(branchName)}/unprotect`);
return this.put(`projects/${pId}/repository/branches/${encodeURI(branchId)}/unprotect`);
}

@@ -42,0 +42,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc