Compare commits
2 Commits
aa1a5bd95d
...
314c43bcda
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
314c43bcda | ||
|
|
6a5bb6a0f8 |
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "traxxx",
|
||||
"version": "1.247.6",
|
||||
"version": "1.247.7",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "traxxx",
|
||||
"version": "1.247.6",
|
||||
"version": "1.247.7",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"@aws-sdk/client-s3": "^3.458.0",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "traxxx",
|
||||
"version": "1.247.6",
|
||||
"version": "1.247.7",
|
||||
"description": "All the latest porn releases in one place",
|
||||
"main": "src/app.js",
|
||||
"scripts": {
|
||||
|
||||
@@ -89,10 +89,10 @@ async function curateData(data) {
|
||||
.leftJoin('entities', 'entities.id', 'releases.entity_id')
|
||||
.leftJoin('entities as parents', 'parents.id', 'entities.parent_id')
|
||||
.modify((builder) => {
|
||||
if (args.channel.charAt(0) === '_') {
|
||||
builder.where('parents.slug', args.entity.slice(1));
|
||||
if (args.network) {
|
||||
builder.where('parents.slug', args.network);
|
||||
} else {
|
||||
builder.where('entities.slug', args.entity);
|
||||
builder.where('entities.slug', args.channel);
|
||||
}
|
||||
})
|
||||
.whereIn('entry_id', stashScenes.map((scene) => scene.entryId || scene.urlId));
|
||||
@@ -133,6 +133,14 @@ async function curateData(data) {
|
||||
}
|
||||
|
||||
async function init() {
|
||||
if (!args.studioId) {
|
||||
throw new Error('No StashDB studio ID specified');
|
||||
}
|
||||
|
||||
if (!args.network && !args.channel) {
|
||||
throw new Error('No traxxx channel or network specified');
|
||||
}
|
||||
|
||||
const res = await unprint.post('https://stashdb.org/graphql', {
|
||||
operationName: 'Scenes',
|
||||
query,
|
||||
|
||||
Reference in New Issue
Block a user