random-parts/Team-Sports-RSVP

Payment reminder email going to wrong person

Opened this issue · 7 comments

The intermediate bees paid column looks like this:

5 James Grey Balance -69, 4-21
6 Vimal Fernandez Credit 4-21
7 Brandon Treece google wallet 1-28-18
8 James Delaney
9 Sean Collier (keeper) paypal 1-25-16
10 Francesca Ramadori zelle 11-4-17
11 Ann Rich Credit 4-21
12 Eileen Bucayan check 0069643686
13 Jessica Tupa paypal 1-26-18
14 Mae Adams

James and Mae have not paid. However, Sean gets a reminder instead of James and Mae doesn't get one at all.

My first thought is the extra "(keeper)" for Sean may be the issue. Add a "-" between the last name and (keeper). Seems like that should not be an issue - However, the script uses the space between the first and last name to split them into an array for iterating over. It may be adding an extra array element throwing off index & count for the retrieving the proper email cell location.

After re-reading the above thought/comment, that makes no logical sense at all why that would break it - I still think that is causing the problem - only because I vaguely remember being uncomfortable with how I was implementing a process - and convinced myself that no one would add 3 names to that cell.

+1 lessons in getting it done over getting it right

I removed the "(keeper)" from the name, but the same thing happens. Next, I'll try re-ordering the rows and see what happens

The NamedRanges appear to be off - were there rows that were deleted on that sheet? It would cause inconsistencies in cell references.
Will have to add a way to prevent those changes - cell reference errors seem to be the most common cause of problems

Not sure; I would probably make a new sheet and copy over replies

Deleting rows throw the ranges off

Google sheets had some bugs with handling ranges consistently. possible work around:

  • adding a row deletion confirmation msg
  • shore up ranges throughout the script