Skip to content

Commit

Permalink
fix: Disable logging unknown data-type in console (#1189)
Browse files Browse the repository at this point in the history
  • Loading branch information
manzt committed Dec 19, 2023
1 parent 13b868b commit b64b872
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release notes

## In progress

- fix: Disable logging unknown data types in console

## v1.13.3

- Inject HiGlass CSS via JS, removing the need to include `hglib.css` in HTML templates.
Expand Down
8 changes: 8 additions & 0 deletions app/scripts/TiledPlot.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -1630,6 +1630,14 @@ class TiledPlot extends React.Component {
*/
getIdealizedTrackPositionsOverlay() {
const evtJson = this.props.draggingHappening;

// For whatever reason, evtJson is sometimes a boolean. This rest of
// this code block assumes it's an object, so we return undefined if
// it's not.
if (typeof evtJson === 'boolean') {
return undefined;
}

const datatype = evtJson.datatype;

if (!(datatype in DEFAULT_TRACKS_FOR_DATATYPE) && !evtJson.defaultTracks) {
Expand Down

0 comments on commit b64b872

Please sign in to comment.