Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
Create a free account

Sheet Workers: setAttrs(Array)

Sheet Author
API Scripter
setAttrs is meant to accept an object parameter. If you pass an array instead (for example, by passing a value to instead of _.mapObject), setAttrs will set attributes with the index values of the passed array (treating the array like an object with numeric keys), instead of throwing an error and/or doing nothing.
Phil B.
Forum Champion
Sheet Author
Thanks for pointing this out Brian, I'll write up a bug for this and take a look at it when I get a chance.