Alt+F4 asks the window to close. If it's the main window, this will by default terminate the message loop, shutting down the application. But the application is free to handle the message whatever way it likes. Asking for confirmation, ignoring it, hiding it or closing the window without terminating the process.
Like many (most?) applications which show a notification icon, discord hides the main window when the user presses Alt+F4 or clicks on the X instead of closing it.
Like many (most?) applications which show a notification icon, discord hides the main window when the user presses Alt+F4 or clicks on the X instead of closing it.