class SyncStatusWorker < Mosquito::QueuedJob
def perform
# code
end
end
SyncStatusWorker.new.enqueue
will throw this compile error
❯ crystal src/start_server.cr
Showing last frame. Use --error-trace for full trace.
In lib/mosquito/src/mosquito/queued_job.cr:107:14
107 | task = build_task
^---------
Error: undefined local variable or method 'build_task' for SyncStatusWorker
To get around it, you can just call params in the head of the class.
Making a job worker with no params like this
will throw this compile error
To get around it, you can just call
params
in the head of the class.Crystal version: 1.1.1 Mosquito Shard version: 0.11.0