small bug fixes in glossary.js