Any way to dispatch a closure in laravel 5?
问题 In laravel 4, I could push a closure onto the queue with queue::push(function...) , but this no longer works in laravel 5. Instead, it appears that I have to make a custom Job class for every function that I want to push onto the queue. Since the functions I want to be pushing are only a couple of lines long, and are only ever used in exactly one place, it really seems like a waste of time and space to be writing up a full class for every case. The best "solutions" I can currently think of,