Added conditional enqueue