1 2 3 4 5 6 7 8
# Adds a period to end of string if not already present function dns::ensure_ending_period(String $s) >> String { if $s[-1] == '.' { $s } else { "${s}." } }