Fixed issue when '# is required' with 1 instance

Fixed bug #1240107

Change-Id: I15864246eab03a3fb54c8aeab9e3e5211719f64c