From 46bd1900b5ff52490e52b5049501880bcc0b1647 Mon Sep 17 00:00:00 2001 From: Muhammad Faraz Maqsood Date: Wed, 8 Nov 2023 15:06:41 +0500 Subject: [PATCH] docs!: add a comment --- ecommerce/static/js/models/course_model.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ecommerce/static/js/models/course_model.js b/ecommerce/static/js/models/course_model.js index 6a0e63f42ec..8b13259d6ff 100644 --- a/ecommerce/static/js/models/course_model.js +++ b/ecommerce/static/js/models/course_model.js @@ -31,6 +31,8 @@ define([ return Backbone.RelationalModel.extend({ urlRoot: '/api/v2/courses/', + // course detail page url was not matching because of missing trailing slash, + // with thi function, trailing slash will be added to match the url url: function() { return Backbone.Model.prototype.url.call(this) + '/'; },