File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
src/renderer/components/snippets Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -182,7 +182,7 @@ const onClickContextMenu = async () => {
182182 }
183183
184184 if (action === ' favorites' ) {
185- snippetStore .patchSnippetsById (props .id , {
185+ await snippetStore .patchSnippetsById (props .id , {
186186 isFavorites: data
187187 })
188188
@@ -192,21 +192,21 @@ const onClickContextMenu = async () => {
192192 track (' snippets/delete-from-favorites' )
193193 }
194194
195- if (type === ' folder' ) {
196- await snippetStore .getSnippetsByFolderIds (folderStore .selectedIds ! )
197- }
195+ await snippetStore .getSnippets ()
198196
199197 if (type === ' favorites' ) {
200- await snippetStore .getSnippets ()
201198 snippetStore .setSnippetsByAlias (type )
202199 }
203200 }
204201
205202 isHighlighted .value = false
206203 isFocused .value = false
207204 snippetStore .isContextState = false
208- snippetStore .selected = undefined
209- snippetStore .selectedMultiple = []
205+
206+ if (snippetStore .selectedIds .length ) {
207+ snippetStore .selected = undefined
208+ snippetStore .selectedMultiple = []
209+ }
210210}
211211
212212const dateFormat = computed (() => {
You can’t perform that action at this time.
0 commit comments