lczech / gappa

A toolkit for analyzing and visualizing phylogenetic (placement) data
GNU General Public License v3.0
56 stars 7 forks source link

proper arithmetic operator #10

Closed frederic-mahe closed 1 year ago

frederic-mahe commented 4 years ago

I love to read your code :-)

== is a string operator. It happens to work fine in this case, but I'd recommend to use the proper arithmetic operator -eq instead.

Also, why not?

contains_element "${guard}" "${unique_guards[@]}" && \
    echo "Header guard '${guard}' is not unique!"

I did not test it, but the logic seems to be the same. If the function returns zero, echo message.

lczech commented 1 year ago

Hi @frederic-mahe, sorry, completely forgot about the PRs here... merged finally! Thank you a lot!