More informative message to the user when no custom sorting specification was found at all

This commit is contained in:
SebastianMC 2022-08-17 20:23:37 +02:00 committed by GitHub
parent 575bc100a5
commit b1a43dff3a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 6 additions and 5 deletions

View File

@ -1,7 +1,7 @@
{
"id": "custom-sort",
"name": "Custom File Explorer sorting",
"version": "0.5.188",
"version": "0.5.189",
"minAppVersion": "0.12.0",
"description": "Allows for manual and automatic, config-driven reordering and sorting of files and folders in File Explorer",
"author": "SebastianMC <SebastianMC.github@gmail.com>",

View File

@ -1,6 +1,6 @@
{
"name": "obsidian-custom-sort",
"version": "0.5.188",
"version": "0.5.189",
"description": "Custom Sort plugin for Obsidian (https://obsidian.md)",
"main": "main.js",
"scripts": {

View File

@ -87,9 +87,9 @@ export default class CustomSortPlugin extends Plugin {
new Notice(`Parsing custom sorting specification SUCCEEDED!`)
} else {
if (anySortingSpecFound) {
errorMessage = errorMessage ? errorMessage : `No custom sorting specification found or only empty specification(s)`
} else {
errorMessage = `No valid '${SORTINGSPEC_YAML_KEY}:' key(s) in YAML front matter or multiline YAML indentation error or general YAML syntax error`
} else {
errorMessage = errorMessage ? errorMessage : `No custom sorting specification found or only empty specification(s)`
}
new Notice(`Parsing custom sorting specification FAILED. Suspending the plugin.\n${errorMessage}`, ERROR_NOTICE_TIMEOUT)
this.settings.suspended = true

View File

@ -1,3 +1,4 @@
{
"0.5.188": "0.12.0"
"0.5.188": "0.12.0",
"0.5.189": "0.12.0"
}