fix js and init stuff