File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -143,10 +143,10 @@ def _json_body_(cls):
143
143
}
144
144
145
145
for field in cls ._fields :
146
- json_point ['fields' ][field ] = point . __dict__ [ field ]
146
+ json_point ['fields' ][field ] = getattr ( point , field )
147
147
148
148
for tag in cls ._tags :
149
- json_point ['tags' ][tag ] = point . __dict__ [ tag ]
149
+ json_point ['tags' ][tag ] = getattr ( point , tag )
150
150
151
151
json .append (json_point )
152
152
return json
Original file line number Diff line number Diff line change @@ -137,7 +137,7 @@ def _json_body_(cls):
137
137
for series_name , data in six .iteritems (cls ._datapoints ):
138
138
json .append ({'name' : series_name ,
139
139
'columns' : cls ._fields ,
140
- 'points' : [[point . __dict__ [ k ] for k in cls ._fields ]
140
+ 'points' : [[getattr ( point , k ) for k in cls ._fields ]
141
141
for point in data ]
142
142
})
143
143
return json
You can’t perform that action at this time.
0 commit comments