Skip to content
Snippets Groups Projects
Commit 0c8d874e authored by syuilo's avatar syuilo
Browse files

lint

parent 0fb9c372
No related branches found
Tags 13.13.0-beta.3
No related merge requests found
......@@ -200,7 +200,7 @@ export function getNoteMenu(props: {
props.translating.value = true;
const res = await os.api('notes/translate', {
noteId: appearNote.id,
targetLang: miLocalStorage.getItem('lang') || navigator.language,
targetLang: miLocalStorage.getItem('lang') ?? navigator.language,
});
props.translating.value = false;
props.translation.value = res;
......
export default function(user: { name?: string | null, username: string }): string {
return user.name || user.username;
return user.name === '' ? user.username : user.name ?? user.username;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment