Skip to content

Commit

Permalink
Merge pull request #86 from percolatestudio/feature/remove-underscore
Browse files Browse the repository at this point in the history
Remove underscore
  • Loading branch information
StorytellerCZ authored May 23, 2023
2 parents 571d05a + ab7fe7b commit 972715c
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 36 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,13 @@ jobs:
- '--release 2.3.5'
- '--release 2.8.0'
# Latest version
- ''
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Install Node.js
uses: actions/setup-node@v1
uses: actions/setup-node@v3
with:
node-version: '14.x'

Expand Down
54 changes: 27 additions & 27 deletions .versions
Original file line number Diff line number Diff line change
@@ -1,49 +1,49 @@
[email protected].0
babel-compiler@7.7.0
[email protected].0
[email protected].1
babel-compiler@7.9.0
[email protected].1
[email protected]
[email protected]
[email protected]
callback-hook@1.3.1
callback-hook@1.4.0
[email protected]
[email protected]
ddp-client@2.5.0
ddp-client@2.6.0
[email protected]
ddp-server@2.4.1
ddp-server@2.6.0
[email protected]
[email protected].1
ecmascript@0.15.3
ecmascript-runtime@0.7.0
ecmascript-runtime-client@0.11.1
ecmascript-runtime-server@0.10.1
[email protected].1
[email protected].2
ecmascript@0.16.2
ecmascript-runtime@0.8.0
ecmascript-runtime-client@0.12.1
ecmascript-runtime-server@0.11.0
[email protected].2
[email protected]
[email protected]
[email protected]
[email protected]
local-test:percolate:migrations@1.0.3
logging@1.2.0
meteor@1.9.3
minimongo@1.7.0
[email protected].5
modules@0.16.0
modules-runtime@0.12.0
mongo@1.12.0
[email protected].2
local-test:percolate:migrations@1.1.0
logging@1.3.1
meteor@1.10.1
minimongo@1.9.0
[email protected].8
modules@0.19.0
modules-runtime@0.13.0
mongo@1.16.0
[email protected].3
[email protected]
[email protected]
npm-mongo@3.9.1
npm-mongo@4.9.0
[email protected]
percolate:migrations@1.0.3
percolate:migrations@1.1.0
[email protected]
[email protected]
react-fast-refresh@0.1.1
react-fast-refresh@0.2.3
[email protected]
[email protected]
[email protected]
socket-stream-client@0.4.0
tinytest@1.1.1
socket-stream-client@0.5.0
tinytest@1.2.1
[email protected]
[email protected]
webapp@1.11.1
webapp@1.13.1
[email protected]
8 changes: 3 additions & 5 deletions migrations_server.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ function createLogger(prefix) {

const logger = Migrations.options?.logger;

if (logger && _.isFunction(logger)) {
if (logger && typeof logger === 'function') {
logger({
level: level,
message: message,
Expand All @@ -98,7 +98,7 @@ Meteor.startup(function() {
log = createLogger('Migrations');

['info', 'warn', 'error', 'debug'].forEach(function(level) {
log[level] = _.partial(log, level);
log[level] = (message) => log(level, message)
});

if (process.env.MIGRATE) Migrations.migrateTo(process.env.MIGRATE);
Expand All @@ -124,9 +124,7 @@ Migrations.add = function(migration) {
Object.freeze(migration);

this._list.push(migration);
this._list = _.sortBy(this._list, function(m) {
return m.version;
});
this._list.sort((a, b) => (a.version > b.version) ? 1 : ((b.version > a.version) ? -1 : 0));
};

// Attempts to run the migrations using command in the form of:
Expand Down
4 changes: 2 additions & 2 deletions package.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ Package.describe({
});

Package.onUse(function(api) {
api.versionsFrom('[email protected]');
api.versionsFrom('[email protected].3');
api.use('ecmascript');
api.use(['underscore', 'check', 'mongo', 'logging'], 'server');
api.use(['check', 'mongo', 'logging'], 'server');
api.mainModule('migrations_server.js', 'server');
api.export('Migrations', 'server');
});
Expand Down

0 comments on commit 972715c

Please sign in to comment.