Socket
Socket
Sign inDemoInstall

amphora-rss

Package Overview
Dependencies
49
Maintainers
5
Versions
9
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.4.0 to 0.4.1

24

index.js
'use strict';
const h = require('highland'),
xml = require('xml');
var log = require('./services/log').setup({ file: __filename });
xml = require('xml'),
format = require('date-fns/format');
let log = require('./services/log').setup({ file: __filename });
/**

@@ -16,3 +18,3 @@ * Elevate category tags into the

return group
.map(function ({ item }) {
.map(({ item }) => {
return item

@@ -38,4 +40,4 @@ .map(entry => entry && entry.category)

function feedMetaTags({ title, description, link, copyright, generator, docs }) {
return function (group) {
var now, siteMeta;
return (group) => {
let now, siteMeta;

@@ -51,3 +53,3 @@ if (!title || !description || !link) {

{ link },
{ lastBuildDate: now.toString() },
{ lastBuildDate: format(now, 'ddd, DD MMM YYYY HH:mm:ss ZZ') }, // Date format must be RFC 822 compliant
{ docs: docs || 'http://blogs.law.harvard.edu/tech/rss' },

@@ -94,7 +96,7 @@ { copyright: copyright || now.getFullYear() },

function sendError(res, e, message) {
var message = message || e.message;
function sendError(res, e, message = e.message) {
const status = 500;
res.status(500);
res.json({ status: 500, message });
res.status(status);
res.json({ status, message });

@@ -131,3 +133,3 @@ log('error', e.message, {

.catch(e => sendError(res, e));
};
}

@@ -134,0 +136,0 @@ module.exports.render = render;

{
"name": "amphora-rss",
"version": "0.4.0",
"version": "0.4.1",
"description": "Convert JSON from Amphora into RSS",

@@ -20,2 +20,3 @@ "main": "index.js",

"clayutils": "^1.0.0",
"date-fns": "^1.29.0",
"highland": "^2.11.1",

@@ -22,0 +23,0 @@ "nymag-fs": "^1.0.1",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc