Skip to content

Commit

Permalink
We have events with the same url
Browse files Browse the repository at this point in the history
  • Loading branch information
captn3m0 committed Apr 1, 2024
1 parent f5aa512 commit 6a84f8f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/event-fetcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,14 +89,14 @@ def find_event(l):
def insert_event_json(conn, url, event_json):
d = json.dumps(event_json)
cursor = conn.cursor()
cursor.execute('INSERT OR IGNORE INTO events (url, event_json) VALUES (?, ?)', (url, d))
cursor.execute('INSERT INTO events (url, event_json) VALUES (?, ?)', (url, d))

def create_events_table():
conn = sqlite3.connect('events.db')
cursor = conn.cursor()
cursor.execute('''
CREATE TABLE IF NOT EXISTS events (
url TEXT UNIQUE,
url TEXT,
event_json TEXT
);
''')
Expand Down

0 comments on commit 6a84f8f

Please sign in to comment.