updated functions and modules