From 12e343f8178b7c9c22a246f5e897ead9553c15c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sophie=20D=C3=A9ziel?= Date: Thu, 21 Sep 2023 14:15:06 +0000 Subject: [PATCH] autocorrect offenses --- app/services/printer_scanner.rb | 2 +- lib/spooler.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/services/printer_scanner.rb b/app/services/printer_scanner.rb index 47f6e5ee..8d7f468d 100644 --- a/app/services/printer_scanner.rb +++ b/app/services/printer_scanner.rb @@ -6,7 +6,7 @@ class PrinterScanner # rubocop:enable Layout/LineLength def call - uris = Printer.all.pluck(:octoprint_uri) + uris = Printer.pluck(:octoprint_uri) ips = use_cache do all_network_ips.select { |ip| octoprint?(ip) } end diff --git a/lib/spooler.rb b/lib/spooler.rb index 1780c6d3..62a0e333 100644 --- a/lib/spooler.rb +++ b/lib/spooler.rb @@ -10,7 +10,7 @@ class Spooler def initialize @workers = {} - Printer.all.each do |printer| + Printer.find_each do |printer| @workers[printer.id] = Spool.new(printer) end end