musora-content-services 2.131.0 → 2.131.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,9 @@
1
+ {
2
+ "permissions": {
3
+ "allow": [
4
+ "Bash(rg:*)",
5
+ "Bash(npm run lint:*)"
6
+ ],
7
+ "deny": []
8
+ }
9
+ }
package/CHANGELOG.md CHANGED
@@ -2,6 +2,17 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [2.131.2](https://github.com/railroadmedia/musora-content-services/compare/v2.131.1...v2.131.2) (2026-02-04)
6
+
7
+ ### [2.131.1](https://github.com/railroadmedia/musora-content-services/compare/v2.131.0...v2.131.1) (2026-02-04)
8
+
9
+
10
+ ### Bug Fixes
11
+
12
+ * add musora to award template ([#765](https://github.com/railroadmedia/musora-content-services/issues/765)) ([692743f](https://github.com/railroadmedia/musora-content-services/commit/692743f950d155e3bda8a8d6675374b4611c5a53))
13
+ * add SP and GC lesson types to progressTypesMapping ([#759](https://github.com/railroadmedia/musora-content-services/issues/759)) ([493ac78](https://github.com/railroadmedia/musora-content-services/commit/493ac78dfadb11e66def4c832d3998033bc133cd))
14
+ * optimize method complete fn ([#755](https://github.com/railroadmedia/musora-content-services/issues/755)) ([23f6429](https://github.com/railroadmedia/musora-content-services/commit/23f6429560234905cdd91f15aca33df0289e9133))
15
+
5
16
  ## [2.131.0](https://github.com/railroadmedia/musora-content-services/compare/v2.130.0...v2.131.0) (2026-02-03)
6
17
 
7
18
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "musora-content-services",
3
- "version": "2.131.0",
3
+ "version": "2.131.2",
4
4
  "description": "A package for Musoras content services ",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
@@ -301,10 +301,10 @@ export const progressTypesMapping = {
301
301
  'song tutorial': [...tutorialsLessonTypes, 'song-tutorial-lesson'],
302
302
  songs: transcriptionsLessonTypes,
303
303
  'play along': playAlongLessonTypes,
304
- 'guided course': ['guided-course'],
304
+ 'guided course': ['guided-course', 'guided-course-lesson'],
305
305
  'course collection': ['course-collection'],
306
306
  'learning path': ['learning-path-v2'],
307
- 'skill pack': skillLessonTypes,
307
+ 'skill pack': [...skillLessonTypes, 'skill-pack-lesson'],
308
308
  'jam track': jamTrackLessonTypes,
309
309
  'course video': ['course-lesson'],
310
310
  }
@@ -1006,6 +1006,10 @@ export const awardTemplate = {
1006
1006
  front: "https://d3fzm1tzeyr5n3.cloudfront.net/v2/awards/playbass.svg",
1007
1007
  rear: "https://d3fzm1tzeyr5n3.cloudfront.net/v2/awards/playbass-rear.svg",
1008
1008
  },
1009
+ musora: {
1010
+ front: null,
1011
+ rear: null,
1012
+ },
1009
1013
  }
1010
1014
 
1011
1015
  /**
@@ -95,6 +95,7 @@ export async function fetchInstructorBySlug(
95
95
  export interface InstructorLessonsOptions extends BuildQueryOptions {
96
96
  searchTerm?: string
97
97
  includedFields?: Array<string>
98
+ contentType?: string
98
99
  }
99
100
 
100
101
  export interface InstructorLessons {
@@ -123,13 +124,13 @@ export interface InstructorLessons {
123
124
  export async function fetchInstructorLessons(
124
125
  slug: string,
125
126
  brand: Brands | string,
126
- contentType?: string,
127
127
  {
128
128
  sort = '-published_on',
129
129
  searchTerm = '',
130
130
  offset = 0,
131
131
  limit = 20,
132
132
  includedFields = [],
133
+ contentType = null
133
134
  }: InstructorLessonsOptions = {}
134
135
  ): Promise<InstructorLessons> {
135
136
  sort = getSortOrder(sort, brand)
@@ -453,17 +453,20 @@ export async function completeMethodIntroVideo(
453
453
  ): Promise<completeMethodIntroVideo> {
454
454
  let response = {} as completeMethodIntroVideo
455
455
 
456
- const methodStructure = await fetchMethodV2Structure(brand)
456
+ const [intro_video_response, methodStructure] = await Promise.all([
457
+ completeIfNotCompleted(introVideoId),
458
+ fetchMethodV2Structure(brand)
459
+ ])
460
+ response.intro_video_response = intro_video_response
457
461
 
458
462
  const firstLearningPathId = methodStructure.learning_paths[0].id
463
+
459
464
  response.active_path_response = await methodIntroVideoCompleteActions(
460
465
  brand,
461
466
  firstLearningPathId,
462
467
  new Date()
463
468
  )
464
469
 
465
- response.intro_video_response = await completeIfNotCompleted(introVideoId)
466
-
467
470
  return response
468
471
  }
469
472
 
@@ -119,8 +119,8 @@ export async function processContentItem(content) {
119
119
  badge: content.badge ?? null,
120
120
  badge_rear: content.badge_rear ?? null,
121
121
  badge_logo: content.logo ?? null,
122
- badge_template: awardTemplate[content.brand].front,
123
- badge_template_rear: awardTemplate[content.brand].rear,
122
+ badge_template: content.badge_template ?? null,
123
+ badge_template_rear: content.badge_template_rear ?? null,
124
124
  isLocked: content.is_locked ?? false,
125
125
  subtitle:
126
126
  collectionLessonTypes.includes(content.type) || content.lesson_count > 1