fix add campaign
This commit is contained in:
parent
5faadaa69b
commit
611f7a02d9
@ -94,10 +94,6 @@ def add_twitter_campaign():
|
||||
user_input = request_json['user_input'],
|
||||
)
|
||||
|
||||
db.session.add(twitter_campaign)
|
||||
db.session.flush()
|
||||
db.session.refresh()
|
||||
|
||||
twitter_campaign_post = TwitterPost(
|
||||
id = str(uuid4()),
|
||||
campaign_id = twitter_campaign.id,
|
||||
@ -106,6 +102,7 @@ def add_twitter_campaign():
|
||||
twitter_post_id = response['id']
|
||||
)
|
||||
|
||||
db.session.add(twitter_campaign)
|
||||
db.session.add(twitter_campaign_post)
|
||||
db.session.commit()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user