fix bug; when ra,dec are given instead of direction