Moved mod_switch functions to posting.py