this will merge conflict with the recent PR i made, but it won't be too hard to fix.