Improve marker code addition
Tidying up