Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -1177,7 +1177,7 @@

async _findIpAllowlist (programId, ipAllowlistId) {
const ipAllowlists = await this.listIpAllowlists(programId)
const ipAllowlist = ipAllowlists.find(i => i.id === ipAllowlistId)
const ipAllowlist = ipAllowlists.find(i => String(i.id) === String(ipAllowlistId))
if (!ipAllowlist) {
throw new codes.ERROR_FIND_IP_ALLOWLIST({ messageValues: [ipAllowlistId, programId] })
}
Expand Down Expand Up @@ -1277,7 +1277,7 @@
*/
async removeIpAllowlistBinding (programId, ipAllowlistId, environmentId, service) {
const ipAllowlist = await this._findIpAllowlist(programId, ipAllowlistId)
let binding = ipAllowlist.bindings.find(b => b.environmentId === environmentId && b.tier === service)
let binding = ipAllowlist.bindings.find(b => String(b.environmentId) === String(environmentId) && b.tier === service)
if (!binding) {
throw new codes.ERROR_FIND_IP_ALLOWLIST_BINDING({ messageValues: [ipAllowlistId, environmentId, service, programId] })
}
Expand Down Expand Up @@ -1310,7 +1310,7 @@
*
* @param {string} programId - the program id
* @param {string} contentSet - the body of the content set.
* @returns {Promise<ContentSet>} the created content set

Check warning on line 1313 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentSet' is undefined

Check warning on line 1313 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentSet' is undefined
*/
async createContentSet (programId, contentSet) {
const url = `/api/program/${programId}/contentSets`
Expand Down Expand Up @@ -1342,7 +1342,7 @@
*
* @param {string} programId - the program id
* @param {string} contentSetId - the content set id
* @returns {Promise<ContentSet>} the content set

Check warning on line 1345 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentSet' is undefined

Check warning on line 1345 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentSet' is undefined
*/
async getContentSet (programId, contentSetId) {
const url = `/api/program/${programId}/contentSet/${contentSetId}`
Expand All @@ -1357,7 +1357,7 @@
* List Content Sets for program
*
* @param {string} programId - the program id
* @returns {Promise<ContentSet[]>} list of the content sets for the program

Check warning on line 1360 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentSet' is undefined

Check warning on line 1360 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentSet' is undefined
*/
async listContentSets (programId) {
const url = `/api/program/${programId}/contentSets`
Expand All @@ -1373,7 +1373,7 @@
* @param {string} programId The program id
* @param {string} contentSetId The content set id
* @param {string} updatedContentSet the body (JSON format)
* @returns {Promise<ContentSet>} the updated content set

Check warning on line 1376 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentSet' is undefined

Check warning on line 1376 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentSet' is undefined
*/
async updateContentSet (programId, contentSetId, updatedContentSet) {
const url = `/api/program/${programId}/contentSet/${contentSetId}`
Expand All @@ -1389,8 +1389,8 @@
*
* @param {string} programId The program id
* @param {string} environmentId The environment id
* @param {ContentFlow} contentFlow The body of the contentFlow

Check warning on line 1392 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentFlow' is undefined

Check warning on line 1392 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentFlow' is undefined
* @returns {Promise<ContentFlow>} the created content flow representation

Check warning on line 1393 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentFlow' is undefined

Check warning on line 1393 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentFlow' is undefined
*/
async createContentFlow (programId, environmentId, contentFlow) {
const url = `/api/program/${programId}/environment/${environmentId}/contentFlow`
Expand All @@ -1406,7 +1406,7 @@
*
* @param {string} programId The program id
* @param {string} contentFlowId the content flow id
* @returns {Promise<ContentFlow>} the Content Flow

Check warning on line 1409 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentFlow' is undefined

Check warning on line 1409 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentFlow' is undefined
*/
async getContentFlow (programId, contentFlowId) {
const url = `/api/program/${programId}/contentFlow/${contentFlowId}`
Expand All @@ -1421,7 +1421,7 @@
* List content flows for program
*
* @param {string} programId The program id
* @returns {Promise<ContentFlow[]>} an array of content flows

Check warning on line 1424 in src/index.js

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 17.x)

The type 'ContentFlow' is undefined

Check warning on line 1424 in src/index.js

View workflow job for this annotation

GitHub Actions / build (macos-latest, 17.x)

The type 'ContentFlow' is undefined
*/
async listContentFlows (programId) {
const url = `/api/program/${programId}/contentFlows`
Expand Down
Loading