Fix matrix multiplyScalar bug