its not clear what is this function doing... better name or comment