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

@doctadevs/knex

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

@doctadevs/knex - npm Package Compare versions

Comparing version 0.0.41 to 0.0.42

1

dist/services/trainings.d.ts
import { Training, TrainingTypeEnum } from '@doctadevs/types';
export declare const trainingCohortExists: (cohortId: string) => Promise<boolean>;
export declare const getTrainingByCohortId: (cohortId: string) => Promise<Training | void>;

@@ -3,0 +4,0 @@ export declare const getTrainings: () => Promise<Training[]>;

@@ -6,3 +6,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.getTrainingSlugsList = exports.trainingCohortHasAvailableSeats = exports.getTrainingCohortAvailableSeats = exports.getTrainingByCurrentCohortAndSlug = exports.getTrainingByCurrentCohort = exports.getTrainingsByType = exports.getTrainings = exports.getTrainingByCohortId = void 0;
exports.getTrainingSlugsList = exports.trainingCohortHasAvailableSeats = exports.getTrainingCohortAvailableSeats = exports.getTrainingByCurrentCohortAndSlug = exports.getTrainingByCurrentCohort = exports.getTrainingsByType = exports.getTrainings = exports.getTrainingByCohortId = exports.trainingCohortExists = void 0;
const types_1 = require("@doctadevs/types");

@@ -20,2 +20,7 @@ const training_1 = __importDefault(require("../transforms/training"));

const activeTrainingSlugsList = (trainingType) => database_1.default(trainingTypeToSlugListView[trainingType]);
const trainingCohortExists = async (cohortId) => {
const trainings = await trainingCohorts().where('training_cohort-id', cohortId).select();
return trainings.length === 1;
};
exports.trainingCohortExists = trainingCohortExists;
const getTrainingByCohortId = async (cohortId) => {

@@ -22,0 +27,0 @@ const trainings = await trainingCohorts().where('training_cohort_id', cohortId).select();

4

package.json
{
"name": "@doctadevs/knex",
"version": "0.0.41",
"version": "0.0.42",
"main": "dist/index.js",

@@ -33,3 +33,3 @@ "types": "dist/index.d.ts",

"dependencies": {
"@doctadevs/types": "^0.0.45",
"@doctadevs/types": "^0.0.47",
"@doctadevs/utils": "^0.0.24",

@@ -36,0 +36,0 @@ "knex": "^0.95.6",

@@ -18,2 +18,8 @@ import { Training, TrainingTypeEnum, TrainingTypes } from '@doctadevs/types';

export const trainingCohortExists = async (cohortId: string): Promise<boolean> => {
const trainings = await trainingCohorts().where('training_cohort-id', cohortId).select();
return trainings.length === 1;
};
export const getTrainingByCohortId = async (cohortId: string): Promise<Training | void> => {

@@ -20,0 +26,0 @@ const trainings = await trainingCohorts().where('training_cohort_id', cohortId).select();

Sorry, the diff of this file is not supported yet

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