fix #484 (took me a while to figure out lol)