Skip to content

Commit

Permalink
Merge pull request #134 from fabian-emilius/master
Browse files Browse the repository at this point in the history
Fix marketplace name overflow
  • Loading branch information
hugomspielworks authored Nov 28, 2023
2 parents 0e78b1c + a0582ec commit 27aa795
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 6 deletions.
1 change: 0 additions & 1 deletion definitions/migrations/1.3.21/database.sql

This file was deleted.

1 change: 0 additions & 1 deletion definitions/migrations/1.3.22/database.sql

This file was deleted.

1 change: 1 addition & 0 deletions definitions/migrations/1.3.23/database.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
UPDATE dbinfo SET "value" = '1.3.23' WHERE name = 'version';
18 changes: 18 additions & 0 deletions definitions/migrations/1.3.24/atomicmarket.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
DROP VIEW atomicmarket_sales_master;
DROP VIEW atomicmarket_auctions_master;
DROP VIEW atomicmarket_buyoffers_master;
DROP VIEW atomicmarket_template_buyoffers_master;

ALTER TABLE atomicmarket_marketplaces ALTER COLUMN marketplace_name TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_sales ALTER COLUMN maker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_sales ALTER COLUMN taker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_sales_filters ALTER COLUMN maker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_sales_filters ALTER COLUMN taker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_auctions ALTER COLUMN maker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_auctions ALTER COLUMN taker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_buyoffers ALTER COLUMN maker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_buyoffers ALTER COLUMN taker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_template_buyoffers ALTER COLUMN maker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_template_buyoffers ALTER COLUMN taker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_stats_markets ALTER COLUMN maker_marketplace TYPE CHARACTER VARYING(13);
ALTER TABLE atomicmarket_stats_markets ALTER COLUMN taker_marketplace TYPE CHARACTER VARYING(13);
1 change: 1 addition & 0 deletions definitions/migrations/1.3.24/database.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
UPDATE dbinfo SET "value" = '1.3.24' WHERE name = 'version';
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eosio-contract-api",
"version": "1.3.22",
"version": "1.3.24",
"description": "EOSIO Contract API",
"author": "pink.gg",
"license": "AGPL-3.0",
Expand Down
10 changes: 7 additions & 3 deletions src/filler/handlers/atomicmarket/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,13 +148,17 @@ export default class AtomicMarketHandler extends ContractHandler {
await client.query(fs.readFileSync('./definitions/views/atomicmarket_sales_master.sql', {encoding: 'utf8'}));
}

if (version === '1.3.21') {
if (version === '1.3.23') {
await client.query(fs.readFileSync('./definitions/views/atomicmarket_template_buyoffers_master.sql', {encoding: 'utf8'}));
await client.query(fs.readFileSync('./definitions/procedures/atomicmarket_template_buyoffer_mints.sql', {encoding: 'utf8'}));
await client.query(fs.readFileSync('./definitions/views/atomicmarket_assets_master.sql', {encoding: 'utf8'}));
}

if (version === '1.3.22') {
await client.query(fs.readFileSync('./definitions/views/atomicmarket_assets_master.sql', {encoding: 'utf8'}));
if (version === '1.3.24') {
await client.query(fs.readFileSync('./definitions/views/atomicmarket_auctions_master.sql', {encoding: 'utf8'}));
await client.query(fs.readFileSync('./definitions/views/atomicmarket_buyoffers_master.sql', {encoding: 'utf8'}));
await client.query(fs.readFileSync('./definitions/views/atomicmarket_template_buyoffers_master.sql', {encoding: 'utf8'}));
await client.query(fs.readFileSync('./definitions/views/atomicmarket_sales_master.sql', {encoding: 'utf8'}));
}
}

Expand Down

0 comments on commit 27aa795

Please sign in to comment.