"Section 35 of Chapter 123 of said General Laws is hereby amended by inserting after the word ???days.???, in line 38, the following language:- The court in its order shall specify whether such commitment is based upon a finding that said person is an alcoholic, a substance abuser, or both, and this information shall be entered in the record to permit transmission to the commissioner of the departm" . . . .