File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
ReactCommon/react/renderer/components/view Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -174,20 +174,26 @@ inline void fromRawValue(
174174 const PropsParserContext &context,
175175 const RawValue &value,
176176 AccessibilityUnit &result) {
177- auto map = (butter::map< std::string, RawValue>)value;
178- /*
177+ // don't use std::string instead use RawValue and add a toString conversion
178+ auto map = (butter::map<std::string, std::string>)value;
179179 auto hours = map.find (" hours" );
180180 if (hours != map.end ()) {
181181 // This probably calls toString()
182- fromRawValue(context, hours->second, result.hours) ;
182+ result. hours = hours->second ;
183183 }
184- */
184+ /*
185185 if (value.hasType<std::string>()) {
186- auto string = " 10 " ;
186+ auto string = toString(value) ;
187187 result.hours = string;
188188 } else {
189189 LOG(ERROR) << "Can not set type string for AccessibilityUnit field hours";
190190 }
191+ */
192+ }
193+
194+ inline std::string toString (
195+ const AccessibilityUnit &accessibilityUnit) {
196+ return " default string" ;
191197}
192198
193199inline std::string toString (
You can’t perform that action at this time.
0 commit comments