Fix scraped tag creation (#1436)

This commit is contained in:
peolic 2021-05-28 02:00:13 +03:00 committed by GitHub
parent c70faa2a53
commit 47ecb9f9b1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 8 deletions

View file

@ -333,9 +333,8 @@ export const GalleryScrapeDialog: React.FC<IGalleryScrapeDialogProps> = (
}
async function createNewTag(toCreate: GQL.ScrapedSceneTag) {
let tagInput: GQL.TagCreateInput = { name: "" };
const tagInput: GQL.TagCreateInput = { name: toCreate.name ?? "" };
try {
tagInput = Object.assign(tagInput, toCreate);
const result = await createTag({
variables: {
input: tagInput,

View file

@ -221,9 +221,8 @@ export const PerformerEditPanel: React.FC<IPerformerDetails> = ({
}
async function createNewTag(toCreate: GQL.ScrapedSceneTag) {
let tagInput: GQL.TagCreateInput = { name: "" };
const tagInput: GQL.TagCreateInput = { name: toCreate.name ?? "" };
try {
tagInput = Object.assign(tagInput, toCreate);
const result = await createTag({
variables: {
input: tagInput,

View file

@ -314,9 +314,8 @@ export const PerformerScrapeDialog: React.FC<IPerformerScrapeDialogProps> = (
}
async function createNewTag(toCreate: GQL.ScrapedSceneTag) {
let tagInput: GQL.TagCreateInput = { name: "" };
const tagInput: GQL.TagCreateInput = { name: toCreate.name ?? "" };
try {
tagInput = Object.assign(tagInput, toCreate);
const result = await createTag({
variables: {
input: tagInput,

View file

@ -445,9 +445,8 @@ export const SceneScrapeDialog: React.FC<ISceneScrapeDialogProps> = (
}
async function createNewTag(toCreate: GQL.ScrapedSceneTag) {
let tagInput: GQL.TagCreateInput = { name: "" };
const tagInput: GQL.TagCreateInput = { name: toCreate.name ?? "" };
try {
tagInput = Object.assign(tagInput, toCreate);
const result = await createTag({
variables: {
input: tagInput,