#NEWLINE# def is_monoasset( self ) : #NEWLINE# #INDENT# 'Returns a boolean representing if the transaction sends\n        coins of exactly 1 color.\n        ' #NEWLINE# if ( not self . targets ) : #NEWLINE# #INDENT# raise InvalidTargetError ( 'Basic txs is empty!' ) #NEWLINE# #UNINDENT# asset = self . targets [ 0 ] . get_asset ( ) #NEWLINE# for target in self . targets : #NEWLINE# #INDENT# if ( target . get_asset ( ) != asset ) : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# #UNINDENT# return True