This should fix the damn bug, even if it slows down the execution a
little bit... But hey, there's a cache now!