mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Linting fixes, remove debug
This commit is contained in:
parent
2b14d51ec6
commit
ed5dfde1a8
2 changed files with 15 additions and 10 deletions
|
|
@ -15,7 +15,6 @@ export const addPopularReadResolver = authorized<
|
|||
AddPopularReadError,
|
||||
MutationAddPopularReadArgs
|
||||
>(async (_, { name }, ctx) => {
|
||||
console.log('************************ addPopularRead ************************')
|
||||
const {
|
||||
models,
|
||||
claims: { uid },
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ import { createPubSubClient } from '../datalayer/pubsub'
|
|||
import { ArticleSavingRequestStatus, Page, PageContext } from '../elastic/types'
|
||||
import { PageType } from '../generated/graphql'
|
||||
import { generateSlug, stringToHash } from '../utils/helpers'
|
||||
import { readFileSync } from 'fs';
|
||||
import { readFileSync } from 'fs'
|
||||
import path from 'path'
|
||||
|
||||
type PopularRead = {
|
||||
|
|
@ -25,9 +25,14 @@ const popularRead = (key: string): PopularRead | undefined => {
|
|||
return undefined
|
||||
}
|
||||
|
||||
|
||||
const content = readFileSync(path.resolve(__dirname, `popular_reads/${key}-content.html`), 'utf8')
|
||||
const originalHtml = readFileSync(path.resolve(__dirname, `./popular_reads/${key}-original.html`), 'utf8')
|
||||
const content = readFileSync(
|
||||
path.resolve(__dirname, `popular_reads/${key}-content.html`),
|
||||
'utf8'
|
||||
)
|
||||
const originalHtml = readFileSync(
|
||||
path.resolve(__dirname, `./popular_reads/${key}-original.html`),
|
||||
'utf8'
|
||||
)
|
||||
if (!content || !originalHtml) {
|
||||
return undefined
|
||||
}
|
||||
|
|
@ -83,7 +88,6 @@ export const addPopularRead = async (
|
|||
return pageId
|
||||
}
|
||||
|
||||
|
||||
const popularReads = [
|
||||
{
|
||||
key: 'omnivore_get_started',
|
||||
|
|
@ -91,7 +95,8 @@ const popularReads = [
|
|||
title: 'Getting Started with Omnivore',
|
||||
author: 'The Omnivore Team',
|
||||
description: 'Get the most out of Omnivore by learning how to use it.',
|
||||
previewImage: 'https://proxy-prod.omnivore-image-cache.app/88x88,sBp_gMyIp8Y4Mje8lzL39vzrBQg5m9KbprssrGjCbbHw/https://substackcdn.com/image/fetch/w_1200,h_600,c_limit,f_jpg,q_auto:good,fl_progressive:steep/https%3A%2F%2Fbucketeer-e05bbc84-baa3-437e-9518-adb32be77984.s3.amazonaws.com%2Fpublic%2Fimages%2F658efff4-341a-4720-8cf6-9b2bdbedfaa7_800x668.gif',
|
||||
previewImage:
|
||||
'https://proxy-prod.omnivore-image-cache.app/88x88,sBp_gMyIp8Y4Mje8lzL39vzrBQg5m9KbprssrGjCbbHw/https://substackcdn.com/image/fetch/w_1200,h_600,c_limit,f_jpg,q_auto:good,fl_progressive:steep/https%3A%2F%2Fbucketeer-e05bbc84-baa3-437e-9518-adb32be77984.s3.amazonaws.com%2Fpublic%2Fimages%2F658efff4-341a-4720-8cf6-9b2bdbedfaa7_800x668.gif',
|
||||
publishedAt: new Date('2021-10-13'),
|
||||
siteName: 'Omnivore Blog',
|
||||
},
|
||||
|
|
@ -101,8 +106,9 @@ const popularReads = [
|
|||
title: 'Organize your Omnivore library with labels',
|
||||
author: 'The Omnivore Team',
|
||||
description: 'Use labels to organize your Omnivore library.',
|
||||
previewImage: 'https://proxy-prod.omnivore-image-cache.app/88x88,sSLRtT7zJbaNFEUbqDe9jbr3nloPsdjaqQXUqISk_x7E/https://substackcdn.com/image/fetch/w_1200,h_600,c_limit,f_jpg,q_auto:good,fl_progressive:steep/https%3A%2F%2Fbucketeer-e05bbc84-baa3-437e-9518-adb32be77984.s3.amazonaws.com%2Fpublic%2Fimages%2Fa4ec9f3c-baef-464b-8d3a-0b8a384874d3_960x711.gif',
|
||||
previewImage:
|
||||
'https://proxy-prod.omnivore-image-cache.app/88x88,sSLRtT7zJbaNFEUbqDe9jbr3nloPsdjaqQXUqISk_x7E/https://substackcdn.com/image/fetch/w_1200,h_600,c_limit,f_jpg,q_auto:good,fl_progressive:steep/https%3A%2F%2Fbucketeer-e05bbc84-baa3-437e-9518-adb32be77984.s3.amazonaws.com%2Fpublic%2Fimages%2Fa4ec9f3c-baef-464b-8d3a-0b8a384874d3_960x711.gif',
|
||||
publishedAt: new Date('2022-04-18'),
|
||||
siteName: 'Omnivore Blog',
|
||||
}
|
||||
]
|
||||
},
|
||||
]
|
||||
|
|
|
|||
Loading…
Reference in a new issue