Simplify some functions