just a bit of monkeypatching