there is a big mistake in this part of code which makes your advice wrong.
You will see it in next commit