From 5f3dc020f0164ef0ae833b07463a40c9c44ae0b6 Mon Sep 17 00:00:00 2001 From: Jon duSaint Date: Sat, 16 Sep 2023 09:24:03 -0700 Subject: Reolink.pm: Clean up args in new Make the previous change here more tidy. --- reolink/Reolink.pm | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/reolink/Reolink.pm b/reolink/Reolink.pm index ea95c4f..56b78c5 100644 --- a/reolink/Reolink.pm +++ b/reolink/Reolink.pm @@ -107,16 +107,11 @@ sub new { pass => $args{pass} // $args{password} // $default_pass, proto => $args{proto} // $default_proto, token => undef, - errors => 0 + errors => 0, + image_quality_workaround => $args{image_quality_workaround} ? 1 : 0, + debug => $args{debug} ? 1 : 0 }; - if ($args{image_quality_workaround}) { - $this->{image_quality_workaround} = 1; - } - if ($args{debug}) { - $this->{debug} = 1; - } - make_url ($this); bless $this, $class; -- cgit v1.2.3