View Single Post
Old 04-21-2023, 06:15 PM   #597
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,024
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
@chaley - I saved the template to has_data(). I did change '1' to 'Yes' so it would match has_cover().

It worked pretty quickly in a saved search so as an extra test I added it to this:
Code:
program: 

formats = approximate_formats();

   strcat
   (
		if "epub" inlist formats then 'formats_epub.png:' fi,
		if "pdf" inlist formats then 'formats_pdf.png:' fi,	
		if "azw3" inlist formats then 'formats_azw3.png:' fi,
		if "mobi" inlist formats then 'formats_mobi.png:' fi,
		if "cbz" inlist formats then 'formats_cbz.png:' fi,	
		if "txt" inlist formats then 'formats_txt.png:' fi,	
		if "paperbook" inlist formats then 'formats_paperbook.png:' fi,
		if "overdrive" inlist formats then 'formats_overdrive.png:' fi,	
		if has_data() == 'Yes' then 'save.png:' fi,
		if list_difference(formats, 'epub, pdf, azw3, mobi, cbz, paperbook, overdrive, txt', ',') then 'formats_unknown.png' fi	
   )
It doesn't seem to be any slower than usual so think I will keep.

Last edited by ownedbycats; 04-21-2023 at 07:43 PM.
ownedbycats is offline   Reply With Quote