Mark terrain status complete when profile already exists
TerrainProfileWorker early-exited with :ok when a profile existed but never updated the contact status, leaving contacts stuck at queued.
This commit is contained in:
parent
00bacae2c2
commit
25d7ec317a
1 changed files with 1 additions and 0 deletions
|
|
@ -19,6 +19,7 @@ defmodule Microwaveprop.Workers.TerrainProfileWorker do
|
|||
@impl Oban.Worker
|
||||
def perform(%Oban.Job{args: %{"contact_id" => contact_id}}) do
|
||||
if Terrain.has_terrain_profile?(contact_id) do
|
||||
Radio.set_enrichment_status!([contact_id], :terrain_status, :complete)
|
||||
:ok
|
||||
else
|
||||
contact = Radio.get_contact!(contact_id)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue