mac: in Swift, why is applicationWillTerminate not called period without exceptions?

This is in the delegate class of the application. Why does HandleApplicationClose() It seems not to be called at all? and how do I fix it?

func applicationWillTerminate(_ aNotification: Notification) {
    HandleApplicationClose()
}

Please help, and fuck whoever drops this