this is the code during master