before function before dotcmd before return after dotcmd after function