Optimize some code regarding python syntax

When you have ></something> you could replace it with a simple /> this
generates less code and in addition I suggest this is more readable