#NEWLINE# @ eventmgr_core . handler ( 'client away' , priority = 1 ) #NEWLINE# def m_away_process( info ) : #NEWLINE# #INDENT# cli = info [ 'source' ] #NEWLINE# if info [ 'away' ] : #NEWLINE# #INDENT# cli . metadata [ 'away' ] = info [ 'away' ] #NEWLINE# cli . dump_numeric ( '306' , [ 'You have been marked as being away' ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( 'away' in cli . metadata ) : #NEWLINE# #INDENT# cli . dump_numeric ( '305' , [ 'You are no longer marked as being away' ] ) #NEWLINE# del info . metadata [ 'away' ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# pass