These notices are telling you that it cannot calculate the shipping order total because it can't find a match between the shipping quote stored in the session variable and the shipping classes stored in the global variable. The delivered code, fixed as suggested, doesn't do this. If you are running it in a test store you can put some debugging into ot_shipping so you can see what's not properly set. Check what $module gets set to in line 48 and if it doesn't look right, check the value of $