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

edx-modulestore

Package Overview
Dependencies
Maintainers
1
Versions
43
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

edx-modulestore - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

33

lib/modulestore.js

@@ -117,2 +117,35 @@ var Q = require('q');

modulestore.findCourse = function (id) {
var self = this;
var deferred = Q.defer();
if (organization) {
filter = {
'$or': [
{ '_id.org': organization.name },
{ 'metadata.display_organization': organization.name }
]
};
}
Module(this.connection).findOne({
'_id.category': 'course',
'_id.course': id
}, function (err, course) {
if (err) {
deferred.reject(new Error(err));
}
else {
var course = new Course(self, model);
course.fetchAboutData().then(function () {
deferred.resolve(course);
});
}
});
return deferred.promise;
};
modulestore.findOrganizations = function (filter) {

@@ -119,0 +152,0 @@ var self = this;

2

package.json
{
"name": "edx-modulestore",
"version": "0.0.3",
"version": "0.0.4",
"description": "Easy browsing of Open edX modulestores",

@@ -5,0 +5,0 @@ "author": "Bertrand Marron",

@@ -9,4 +9,18 @@ # edx-modulestore

## Documentation
### Courses
#### States
State | Description | Can enroll? | Can access?
--- | --- | --- | ---
`hidden` | Course is not open for enrollment | No | No
`upcoming` | Course is open for enrollment but not running | Yes | No
`open` | Course is open for enrollment and running | Yes | Yes
`finishing` | Course is running but enrollement is closed | No | Yes
`finished` | Course is closed | No | No
## License
[MIT License](http://en.wikipedia.org/wiki/MIT_License)
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