Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
zhouop0 committed Jun 21, 2024
1 parent d046991 commit e17de93
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
8 changes: 4 additions & 4 deletions docs/sql/postgres.sql
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ CREATE DATABASE dispute_explorer WITH ENCODING ='UTF8';
\c dispute_explorer;

-- Create sync_blocks table
DROP TABLE sync_blocks;
DROP TABLE if exists sync_blocks;
CREATE TABLE IF NOT EXISTS sync_blocks
(
id SERIAL PRIMARY KEY,
Expand All @@ -25,7 +25,7 @@ CREATE INDEX if not exists tx_count_index ON sync_blocks (tx_count);
CREATE INDEX if not exists check_count_index ON sync_blocks (check_count);

-- Create sync_events table
DROP TABLE sync_events;
DROP TABLE if exists sync_events;
CREATE TABLE IF NOT EXISTS sync_events
(
id SERIAL PRIMARY KEY,
Expand All @@ -50,7 +50,7 @@ CREATE TABLE IF NOT EXISTS sync_events
-- ----------------------------
-- Table structure for dispute_game
-- ----------------------------
Drop table dispute_game;
Drop table if exists dispute_game;
CREATE TABLE IF NOT EXISTS dispute_game
(
id SERIAL PRIMARY KEY,
Expand All @@ -77,7 +77,7 @@ CREATE INDEX if not exists dispute_game_index ON dispute_game (contract_address,
-- ----------------------------
-- Table structure for game_claim_data
-- ----------------------------
DROP TABLE game_claim_data;
DROP TABLE if exists game_claim_data;
CREATE TABLE IF NOT EXISTS game_claim_data
(
id SERIAL PRIMARY KEY,
Expand Down
1 change: 0 additions & 1 deletion internal/handler/disputeGame.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@ func (r *RetryDisputeGameClient) addDisputeGame(ctx context.Context, evt *schema
GameType: disputeGame.GameType,
L2BlockNumber: l2Block.Int64(),
Status: status,
InitStatus: schema.DisputeGameInit,
}
err = r.DB.Transaction(func(tx *gorm.DB) error {
err = tx.Save(gameClaim).Error
Expand Down
1 change: 0 additions & 1 deletion internal/schema/dispute_game.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ type DisputeGame struct {
GameType uint32 `json:"game_type"`
L2BlockNumber int64 `json:"l_2_block_number"`
Status uint8 `json:"status"`
InitStatus uint8 `json:""`
}

func (DisputeGame) TableName() string {
Expand Down

0 comments on commit e17de93

Please sign in to comment.