Fixed issue #434 where forlayer
would set _n
improperly
#443
+19
−2
forlayer
would set _n
improperly
#443