update 3 functions
merged with magster