#NEWLINE# def fake_network_create_safe( context , values ) : #NEWLINE# #INDENT# net = dict ( network_fields ) #NEWLINE# net [ 'id' ] = ( max ( ( [ n [ 'id' ] for n in networks ] or [ ( - 1 ) ] ) ) + 1 ) #NEWLINE# for key in values : #NEWLINE# #INDENT# net [ key ] = values [ key ] #NEWLINE# #UNINDENT# return FakeModel ( net )