- 'comment' => $comment,
- 'includes' => $includes,
- 'opt_architecture' => $architecture,
- 'allow_unsigned' => $allow_unsigned,
- 'location' => $_location,
- 'release' => $_release,
- 'repos' => $repos,
- })
+ 'comment' => $comment,
+ 'includes' => $includes,
+ 'options' => delete_undef_values({
+ 'arch' => $_architecture,
+ 'trusted' => $allow_unsigned ? { true => 'yes', false => undef },
+ 'allow-insecure' => $allow_insecure ? { true => 'yes', false => undef },
+ 'signed-by' => $keyring,
+ 'check-valid-until' => $check_valid_until? { true => undef, false => 'false' },
+ },
+ ),
+ 'location' => $_location,
+ 'release' => $_release,
+ 'repos' => $repos,
+ }
+ )