modified package js and error codes