Reformated OPLib.js