def _getLastMessage(acc):
 path = os.path.expanduser((('~/Library/Application Support/Skype/' + getUserName()) + '/main.db'))
 with contextlib.closing(sqlite3.connect(path).cursor()) as db:
  db.execute('SELECT timestamp,body_xml FROM Messages WHERE author=? ORDER BY timestamp DESC LIMIT 1', (acc,))
  return db.fetchone()

def _getLastMessage ( acc ) : path = os . path . expanduser ( ( ( '~/Library/Application Support/Skype/' + getUserName ( ) ) + '/main.db' ) ) with contextlib . closing ( sqlite3 . connect ( path ) . cursor ( ) ) as db : db . execute ( 'SELECT timestamp,body_xml FROM Messages WHERE author=? ORDER BY timestamp DESC LIMIT 1' , ( acc , ) ) return db . fetchone ( )
get the last message that a user sent to the currently logged in user .