[UserPage] Fix tags on BrewItem
See original GitHub issueAs the tags
data object was originally a string (''
), when this was converted to an array (I assume using [].concat(tags)
, it resulted in the first item in the array being an empty string. As the current logic is only to check for the existence of an array (using tags.length > 0
), every tags
array will result in the logic evaluating to true.
When the tags
array is populated with data, the first item (tags[0]
) will contain actual data.
Instead, we must not only check for the presence of an array, but also that the first item is NOT an empty string.
([].concat(brew.tags)[0]!='')
was the logic used in the (now closed) #2330; it should only be a case of readding this logic to the ListPage.jsx logic.
Issue Analytics
- State:
- Created a year ago
- Comments:15 (4 by maintainers)
Top Results From Across the Web
FIX 4.2: Fields by Tag – FIX Dictionary - OnixS
FIX 4.2: Fields by Tag – FIX Dictionary – Onix Solutions.
Read more >Text <58> field – FIX 4.2 – FIX Dictionary - OnixS
Used In. Description. Free format text string. (Note: this field does not have a specified maximum length). Used In. Reject <3> · Logout...
Read more >SenderSubID <50> field – FIX 4.2 – FIX Dictionary - OnixS
FIX 4.2 : SenderSubID <50> field. Type: String. Used In. Description. Assigned value used to identify specific message originator (desk, trader, ...
Read more >Side <54> field – FIX 4.2 – FIX Dictionary - OnixS
Side <54> field – FIX 4.2 – FIX Dictionary – Onix Solutions.
Read more >ForexReq <121> field – FIX 4.2 – FIX Dictionary - OnixS
Used In. Description. Indicates request for forex accommodation trade to be executed along with security transaction. Valid values:.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
That’s what I’ve just been looking into… I’ve put in a
tags
array filter that eliminates empty strings immediately prior to updating an existing brew; this should also have the benefit of converting anytags
string that has made it this far through the piece to an array,Alright, looks like the issue, such as it was, has already been resolved by the latest changes to NewPage.jsx getInitialState and componentDidMount. So future brews won’t be affected by the
tags[0]=''
issue.