Skip to content

Commit 85e6e92

Browse files
committed
feat: Drop canShowUpgradeSock course data.
DEPR: openedx/edx-platform#36429 This piece of data is not being used anywhere but was still being consumed so just drop the data so that the backend can be updated to no longer provide the data. The backend API is being updated in openedx/edx-platform#36436
1 parent 360af1f commit 85e6e92

File tree

6 files changed

+0
-9
lines changed

6 files changed

+0
-9
lines changed

src/course-home/data/__factories__/outlineTabData.factory.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ Factory.define('outlineTabData')
3131
course_access_redirect: false,
3232
has_scheduled_content: null,
3333
access_expiration: null,
34-
can_show_upgrade_sock: false,
3534
cert_data: {
3635
cert_status: null,
3736
cert_web_view_url: null,

src/course-home/data/__snapshots__/redux.test.js.snap

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -489,7 +489,6 @@ exports[`Data layer integration tests Test fetchOutlineTab Should fetch, normali
489489
"outline": {
490490
"course-v1:edX+DemoX+Demo_Course": {
491491
"accessExpiration": null,
492-
"canShowUpgradeSock": false,
493492
"certData": {
494493
"certStatus": null,
495494
"certWebViewUrl": null,

src/course-home/data/api.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,6 @@ export async function getOutlineTabData(courseId) {
367367
} = tabData;
368368

369369
const accessExpiration = camelCaseObject(data.access_expiration);
370-
const canShowUpgradeSock = data.can_show_upgrade_sock;
371370
const certData = camelCaseObject(data.cert_data);
372371
const courseBlocks = data.course_blocks ? normalizeOutlineBlocks(courseId, data.course_blocks.blocks) : {};
373372
const courseGoals = camelCaseObject(data.course_goals);
@@ -389,7 +388,6 @@ export async function getOutlineTabData(courseId) {
389388

390389
return {
391390
accessExpiration,
392-
canShowUpgradeSock,
393391
certData,
394392
courseBlocks,
395393
courseGoals,

src/course-home/data/pact-tests/lmsPact.test.jsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ describe('Course Home Service', () => {
4646
willRespondWith: {
4747
status: 200,
4848
body: {
49-
can_show_upgrade_sock: boolean(false),
5049
verified_mode: like({
5150
access_expiration_date: null,
5251
currency: 'USD',
@@ -94,7 +93,6 @@ describe('Course Home Service', () => {
9493
},
9594
});
9695
const normalizedTabData = {
97-
canShowUpgradeSock: false,
9896
verifiedMode: {
9997
accessExpirationDate: null,
10098
currency: 'USD',

src/courseware/data/pact-tests/lmsPact.test.jsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,6 @@ describe('Courseware Service', () => {
192192
upgradeDeadline: '2013-02-05T05:00:00Z',
193193
upgradeUrl: 'link',
194194
},
195-
canShowUpgradeSock: false,
196195
contentTypeGatingEnabled: false,
197196
id: 'course-v1:edX+DemoX+Demo_Course',
198197
title: 'Demonstration Course',
@@ -256,7 +255,6 @@ describe('Courseware Service', () => {
256255
}),
257256
upgrade_url: string('link'),
258257
},
259-
can_show_upgrade_sock: boolean(false),
260258
content_type_gating_enabled: boolean(false),
261259
end: term({
262260
generate: '2013-02-05T05:00:00Z',

src/courseware/data/utils.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ export function normalizeMetadata(metadata) {
7373
const { data, headers } = metadata;
7474
return {
7575
accessExpiration: camelCaseObject(data.access_expiration),
76-
canShowUpgradeSock: data.can_show_upgrade_sock,
7776
contentTypeGatingEnabled: data.content_type_gating_enabled,
7877
courseGoals: camelCaseObject(data.course_goals),
7978
id: data.id,

0 commit comments

Comments
 (0)