x/tools/present: fix null notes value on initial slide

Change-Id: I370fdf2ef7de33976028f8cd872402a08d8f103c
Reviewed-on: https://go-review.googlesource.com/24050
Reviewed-by: Andrew Gerrand <adg@golang.org>
This commit is contained in:
Audrey Lim 2016-06-13 13:54:00 -07:00 committed by Andrew Gerrand
parent 95963e031d
commit 3d35e41306
1 changed files with 1 additions and 2 deletions

View File

@ -32,7 +32,7 @@ function initNotes() {
var slidesUrl = window.location.href; var slidesUrl = window.location.href;
var curSlide = parseInt(localStorage.getItem('destSlide'), 10); var curSlide = parseInt(localStorage.getItem('destSlide'), 10);
var formattedNotes; var formattedNotes = '';
var section = sections[curSlide - 1]; var section = sections[curSlide - 1];
// curSlide is 0 when initialized from the first page of slides. // curSlide is 0 when initialized from the first page of slides.
// Check if section is valid before retrieving Notes. // Check if section is valid before retrieving Notes.
@ -77,7 +77,6 @@ function initNotes() {
w.addEventListener('storage', updateNotes, false); w.addEventListener('storage', updateNotes, false);
}; };
function formatNotes(notes) { function formatNotes(notes) {
var formattedNotes = ''; var formattedNotes = '';
if (notes) { if (notes) {