Was luckily working correctly, but was accessing the artist "global" variable, instead of the passed parameter.