ugh. wasted JS time...