mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 03:19:46 +00:00
refactor: just import config.ts directly instead of loading dotenv in trends.ts script
This commit is contained in:
parent
e7f5e563f5
commit
a5def9fa6c
1 changed files with 1 additions and 7 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
import * as dotenv from '@std/dotenv';
|
|
||||||
import { z } from 'zod';
|
import { z } from 'zod';
|
||||||
|
import '@/config.ts';
|
||||||
|
|
||||||
import {
|
import {
|
||||||
updateTrendingEvents,
|
updateTrendingEvents,
|
||||||
|
|
@ -9,12 +9,6 @@ import {
|
||||||
updateTrendingZappedEvents,
|
updateTrendingZappedEvents,
|
||||||
} from '@/trends.ts';
|
} from '@/trends.ts';
|
||||||
|
|
||||||
await dotenv.load({
|
|
||||||
export: true,
|
|
||||||
defaultsPath: null,
|
|
||||||
examplePath: null,
|
|
||||||
});
|
|
||||||
|
|
||||||
const trendSchema = z.enum(['pubkeys', 'zapped_events', 'events', 'hashtags', 'links']);
|
const trendSchema = z.enum(['pubkeys', 'zapped_events', 'events', 'hashtags', 'links']);
|
||||||
const trends = trendSchema.array().parse(Deno.args);
|
const trends = trendSchema.array().parse(Deno.args);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue