# \[F\] $meta() values lack meaning inside $if()

**URL:** https://community.mp3tag.de/t/f-meta-values-lack-meaning-inside-if/12113
**Category:** Fixed Bugs
**Tags:** bug-fixed
**Created:** [June 7, 2011, 3:32pm UTC](https://community.mp3tag.de/t/f-meta-values-lack-meaning-inside-if/12113 "2011-06-07T15:32:47Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [June 7, 2011, 4:09pm UTC](https://community.mp3tag.de/t/f-meta-values-lack-meaning-inside-if/12113/2 "2011-06-07T16:09:51Z")

</div>

> [@ptrk.mj](#):
>
> ... $if2($meta(artist),no artist)  
> returns no artist in Mp3tag  
> returns value of $meta(artist) in foobar2000
> 
> It makes writing scripts more difficult.  
> In my view, this should be made to work as in foobar.

Can be written as ...  
... boolean ...  
$iflonger($meta(artist),,1,0)  
... string ...  
$iflonger($meta(artist),,$meta(artist),)

To tweak $if2 to expose the same behaviour when its argument is a text string output from $meta rather than a tag-field resp. tag-field content, there might be done some programming hard work to do.

DD.20110607.2010.CEST

---

_[View the full topic](https://community.mp3tag.de/t/f-meta-values-lack-meaning-inside-if/12113)._
