View Single Post
Old 04-16-2021, 01:07 AM   #45
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 11,063
Karma: 75568269
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
This (it's still a WIP; I am still debating whether this will be better than multiple non-template rules) returns a syntax error about an unexpected end of program near "unknown." Where exactly is the mistake?

Code:
program:
	vl = $#vls;
	pc = $$#pagecount;
	fmt = $$#formats;
	lang = $$#languages

	if
		'Cleanup' in vl
	then
		
# Checks for a missing format
		if
			fmt == ''
		then
			'add_book.png'
		fi
			
# Checks for a missing pagecount
		if
			pc == 'None'
		then
			'cover_flow.png'
		fi
		
# Checks for a missing language
		if
			lang == 'None'
		then
			'languages.png'
		fi
		
# Checks for an ORIGINAL_EPUB in formats
		if
			fmt == 'ORIGINAL_EPUB'
		then
			'add_book.png'
		fi

# Returns a generic icon if no specific issue is flagged
	else 
		'polish.png'
	fi

Last edited by ownedbycats; 04-16-2021 at 01:18 AM.
ownedbycats is online now   Reply With Quote