Skip to content

Commit

Permalink
🔀 Merge pull request #1205 from TF2Autobot/fix-name-to-sku
Browse files Browse the repository at this point in the history
🔨 make sure to convert all name to sku if too long
  • Loading branch information
idinium96 authored Jul 12, 2022
2 parents b61632e + 91714dc commit 2793714
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/classes/Listings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,8 @@ export default class Listings {
}

if (!entry.id && details.includes(entry.name)) {
details = details.replace(entry.name, entry.sku);
const regex = new RegExp(entry.name, 'g');
details = details.replace(regex, entry.sku);

if (details.length < 200) {
// if details < 200 after replacing name with sku, use this.
Expand Down

0 comments on commit 2793714

Please sign in to comment.