Removes unnecessary text selection validation check
Eliminates redundant empty selection check in cleanup command Allows processing of empty selections by removing the initial validation preventing user action when no text is selected
This commit is contained in:
1 file changed
-5
@@ -42,11 +42,6 @@ export class CleanupCommand {
|
||||
// Get selected text
|
||||
const selectedText = editor.getSelection();
|
||||
|
||||
if (!selectedText || selectedText.trim().length === 0) {
|
||||
new Notice('Please select some text to clean up');
|
||||
return;
|
||||
}
|
||||
|
||||
// Validate text selection before proceeding
|
||||
const validation = this.validateSelection(selectedText);
|
||||
if (!validation.isValid) {
|
||||
|
||||
Reference in new issue
Block a user