Closed SlipperyJim closed 5 years ago
I can't seem to be able to reproduce this. On my local install I attempted to run the script on several games with no links listed in Links tab. The script added the MetaCritic/IGDB link as the first link without any errors.
Are you deleting existing links and then running it? Because that works on mine as well. It is only when the game has never had a link that it happens (at least for me and it is consistent - have tried it on three different games now).
Added a check for null on the Links collection, which is apparently returned when the game has never had any links. A new Links collection is initialized and added to the game, which allows the attempt to add a link to be successful.
Thanks - now works perfectly for me. Hope you carry on and add some more functionality if possible - Playnite could do with some extensions to add more metadata.
Error is 'You cannot call a method on a null-valued expression'