fix $ undefined