fix add_check_digit to take zero-padded and non-zero-padded GTINs

`add_check_digit` was a bit buggy when you gave it zero-padded GTINs or GTINs that were not 13 characters long. This fixes it to handle all combinations of zero-padded and non-zero-padded GTINs of different lengths.