The difference is that functionOne is a function expression and so only defined when that line is reached, whereas functionTwo is a function declaration and is defined as soon as its surrounding function or script is executed (due to hoisting). For example, a function expression:
Online, collaborative spreadsheets. Google Sheets helps you track, organize and analyze your data on any device. Format and polish data with a few clicks, collaborate in real-time and input accurate, rich data using smart chips for names, files, dates, dropdown menus, events and more. Sign in
The other thing I noticed while the problem occurs is this error message in the Windows Event log:
Calendar live tile stuck. W10 Mobile good day. The live tile stuck on an old event. Then after deleting it would not update. Soft restarts did not clear it. Tried some workarounds and now just say Outlook Calendar Any advice. [Many posts from a year ago [exactly 2nd to 4th Feb 2017] Cheers Andrew Answer AP andy poulton
To access the System log select Start, Control Panel, Administrative Tools, Event Viewer, from the list in the left side of the window expand Windows Logs and select System. Place the cursor on System, select Action from the Menu and Save All Events as (the default evtx file type) and give the file a name. Do not provide filtered files.
Problem Event Name: APPCRASH Application Name: spoolsv.exe Application Version: 6.0.6001.18000 Application Timestamp: 4791a2af Fault Module Name: ZSR.dll Fault Module Version: 6.20.1625.0 Fault Module Timestamp: 462fe8cf Exception Code: c0000005 Exception Offset: 000000000002b54c OS Version: 6.0.6001.2.1.0.768.3 Locale ID: 4105 Additional ...