Skip to content

Commit

Permalink
fix: don't use anonymous function when it is named
Browse files Browse the repository at this point in the history
  • Loading branch information
aminya committed Dec 29, 2020
1 parent 9e4b2f5 commit 2f9392a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/minimap-element.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,22 @@ const elementResizeDetector = elementResizeDetectorImport({ strategy: 'scroll' }

let overlayStyle

const ensureOverlayStyle = () => {
function ensureOverlayStyle () {
if (!overlayStyle) {
overlayStyle = document.createElement('style')
overlayStyle.setAttribute('context', 'atom-text-editor-minimap')
document.head.appendChild(overlayStyle)
}
}

const removeOverlayStyle = () => {
function removeOverlayStyle () {
if (overlayStyle) {
overlayStyle.parentNode.removeChild(overlayStyle)
overlayStyle = null
}
}

const updateOverlayStyle = (basis) => {
function updateOverlayStyle (basis) {
if (overlayStyle) {
overlayStyle.textContent = `
atom-text-editor[with-minimap].editor > div,
Expand Down

0 comments on commit 2f9392a

Please sign in to comment.