MCPcopy
hub / github.com/su-kaka/gcli2api / logout

Function logout

front/common.js:898–906  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

896}
897
898function logout() {
899 localStorage.removeItem('gcli2api_auth_token');
900 AppState.authToken = '';
901 document.getElementById('loginSection').classList.remove('hidden');
902 document.getElementById('mainSection').classList.add('hidden');
903 showStatus('已退出登录', 'info');
904 const passwordInput = document.getElementById('loginPassword');
905 if (passwordInput) passwordInput.value = '';
906}
907
908function handlePasswordEnter(event) {
909 if (event.key === 'Enter') login();

Callers

nothing calls this directly

Calls 1

showStatusFunction · 0.85

Tested by

no test coverage detected