diff --git a/tools/tidyall b/tools/tidyall index fa42f72..e3483b7 100755 --- a/tools/tidyall +++ b/tools/tidyall @@ -23,8 +23,7 @@ sub perltidy_version { # is to separate the qualifier from the actual version with a space. # # It's safe enough to assume that the last item is really the version. - my @version_components = split(' ', $version); - return pop(@version_components); + return split(' ', $version)[-1]; } sub is_force_flag { $_ eq '--force' }