Real fix for the scale function.