Added automatic detection of bytecode loading