I had to move
ids = $identifiers; to the first line to prevent an error, but now I'm getting odd results.
e.g.
Status: In-Progress
Publisher: Archive of Our Own
identifiers: url, ao3
Intended result: null
Actual result: metadata.png
I am getting the same thing for FanFiction.net/ffnet.
modifying my original code like this does get the intended results though:
Code:
program:
status = $#fanficstatus;
publisher = $publisher;
ids = $identifiers;
u = select(ids, 'url');
a = select(ids, 'ao3');
f = select(ids, 'ffnet');
if
(a || f)
&& u
&& '(Archive of Our Own|Fanfiction.net)' in publisher
&& '(Completed|Abandoned|Oneshot)' in status
then "metadata.png:"
elif
!a
&& u
&& publisher = 'Archive of Our Own'
&& status = 'In-Progress'
then "metadata.png:"
elif
!f
&& u
&& publisher = 'FanFiction.net'
&& status = 'In-Progress'
then "metadata.png:"
fi