nuked some global variables that got leaked, fixed loading of inline resources