Enable/disable an item in UI when using a repeater and data set

Hi iamteejay,
I have been super busy, but finally tried to use the code you gave me and I’m getting an error, unfortunately the debug console is no longer displaying it, instead opting to spam “To debug this code, open lzhdo.js in Developer Tools.” (which I can’t find). The code you sent isn’t picking up if the Dataset has a .pdf in it, I tried changing “if (!item.button)” to the below, and several others (item.document & .pdf) but I’ve not had any success. Below I’ve included a picture of what the dataset looks like, along with the modifications to the code.