             window.onafterprint = => @afterPrint()
 
         printMap: (notOnBeforePrint) =>
-            if !notOnBeforePrint and !document.getElementById('map-as-png')
+            if !notOnBeforePrint and !document.getElementById 'map-as-png'
                 alert i18n.t 'print.use_print_button'
                 return
             if @makingPrint or @printed == false

                        div.textContent = marker.unit.attributes.name[p13n.getLanguage()]
                        markerLegend.appendChild div
                    listOfUnits.appendChild(markerLegend)
            leafletImage map, (err, canvas) =>
                if err
                    throw err

            vid = 0
            for own id, marker of markers
                # Settings altered for printing. These will be reset after printing.
                printStore =
                    storeAttributes: ['iconSize', 'iconAnchor']
                for att in printStore.storeAttributes
                    if marker.options.icon.options[att]
                        printStore[att] = marker.options.icon.options[att]
