captain-log
Advanced tools
Comparing version 0.1.2 to 0.1.3
14
index.js
@@ -19,3 +19,2 @@ const request = require('request') | ||
function display (config, data) { | ||
console.log(`### ${config.title}`) | ||
// TODO if data is not array, complain, we have got an error | ||
@@ -27,2 +26,15 @@ data | ||
} | ||
if (config.freshness) { | ||
console.log('freshness') | ||
const since = new Date(config.since) | ||
const created_at = new Date(d.created_at) | ||
if (config.freshness === 'new' && since < created_at) { | ||
return false | ||
} | ||
if (config.freshness === 'updated' && since > created_at) { | ||
return false | ||
} | ||
} | ||
if (config.exclude_labels) { | ||
@@ -29,0 +41,0 @@ const excluded = d.labels |
{ | ||
"name": "captain-log", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"description": "The log from your favorite captains", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6649
5
128