Skip to content

Commit

Permalink
fix gotoobject giving 0 ra or 0 dec
Browse files Browse the repository at this point in the history
  • Loading branch information
bmatthieu3 committed Apr 25, 2024
1 parent d655d8f commit 669fb26
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
"dateModified": "2023-01-31",
"issueTracker": "https://github.com/cds-astro/aladin-lite/issues",
"name": "Aladin Lite",
"version": "3.3.2",
"softwareVersion": "3.3.2",
"version": "3.3.3-beta",
"softwareVersion": "3.3.3-beta",
"description": "An astronomical HiPS visualizer in the browser.",
"identifier": "10.5281/zenodo.7638833",
"applicationCategory": "Astronomy, Visualization",
Expand Down
2 changes: 1 addition & 1 deletion src/core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "aladin-lite"
description = "Aladin Lite v3 introduces a new graphical engine written in Rust with the use of WebGL"
license = "BSD-3-Clause"
repository = "https://github.com/cds-astro/aladin-lite"
version = "3.3.2"
version = "3.3.3-beta"
authors = [ "[email protected]", "[email protected]",]
edition = "2018"

Expand Down
1 change: 0 additions & 1 deletion src/js/Aladin.js
Original file line number Diff line number Diff line change
Expand Up @@ -1009,7 +1009,6 @@ export let Aladin = (function () {
var coo = new Coo();
coo.parse(targetName);
// Convert from view coo sys to icrs

const [ra, dec] = this.wasm.viewToICRSCooSys(coo.lon, coo.lat);

this.view.pointTo(ra, dec);
Expand Down
3 changes: 2 additions & 1 deletion src/js/View.js
Original file line number Diff line number Diff line change
Expand Up @@ -1865,9 +1865,10 @@ export let View = (function () {
ra = parseFloat(ra);
dec = parseFloat(dec);

if (!ra || !dec) {
if (!Number.isFinite(ra) || !Number.isFinite(dec)) {
return;
}

this.viewCenter.lon = ra;
this.viewCenter.lat = dec;
//this.updateLocation({lon: this.viewCenter.lon, lat: this.viewCenter.lat});
Expand Down

0 comments on commit 669fb26

Please sign in to comment.