<p>It should be <code>$event-&gt;parsedValue</code> - see here - <a href="https://github.com/craftcms/feed-me/blob/develop/src/services/Fields.php#L225" rel="nofollow noreferrer">https://github.com/craftcms/feed-me/blob/develop/src/services/Fields.php#L225</a></p>

CC BY-SA 4.0
2020-11-26T16:59:01.547Z
Don't suppose you could help me with this error I'm now getting `Setting unknown property: craft\feedme\events\FieldEvent::isValid - BaseObject.php: 163`?
JMKelley
CC BY-SA 4.0
2020-11-26T20:32:14.880Z
Is this in relation to your bountied post? If I understood correctly, I don’t think it’s doable with Feed Me as it is.
Oli
CC BY-SA 4.0
2020-11-26T20:33:32.187Z
And in relation to this question, isValid is not available on this event.
Oli
CC BY-SA 4.0
2020-11-26T16:08:00.590Z
2020-11-26T16:08:00.590Z
Oli
<p>Getting a strange error when trying to check if a field is null when importing via FeedMe</p>
<blockquote>
<p>Getting unknown property: craft\feedme\events\FieldEvent::fieldValue</p>
</blockquote>
<pre><code>use yii\base\Event;
use craft\feedme\events\FieldEvent;
use craft\feedme\events\ElementEvent;
use craft\helpers\ElementHelper;
use craft\elements\Entry;

Event::on(Fields::class, Fields::EVENT_AFTER_PARSE_FIELD, function(FieldEvent $event) {
    switch($event-&gt;feed['name']){
    case 'offers':
    if ($event-&gt;fieldHandle === 'merchants' &amp;&amp; $event-&gt;fieldValue == null) {
    $event-&gt;isValid=false;
    }
    break;
}
});
</code></pre>

<plugin-development><plugin-feedme>
Getting unknown property: craft\feedme\events\FieldEvent::fieldValue
# Getting unknown property: craft\feedme\events\FieldEvent::fieldValue

(Asked by: username_0 on 2020-11-26)

Getting a strange error when trying to check if a field is null when importing via FeedMe

Getting unknown property: craft\feedme\events\FieldEvent::fieldValue

use yii\base\Event;
use craft\feedme\events\FieldEvent;
use craft\feedme\events\ElementEvent;
use craft\helpers\ElementHelper;
use craft\elements\Entry;

Event::on(Fields::class, Fields::EVENT_AFTER_PARSE_FIELD, function(FieldEvent $event) {
    switch($event->feed['name']){
    case 'offers':
    if ($event->fieldHandle === 'merchants' && $event->fieldValue == null) {
    $event->isValid=false;
    }
    break;
}
});

**Tags:** plugin-development, plugin-feedme

---

## 1 answers

### Answer by username_1 on 2020-11-26. Score: 2 | Accepted answer

It should be `$event->parsedValue` - see here - <https://github.com/craftcms/feed-me/blob/develop/src/services/Fields.php#L225>

> **Comments:**
> **username_0**: Don't suppose you could help me with this error I'm now getting `Setting unknown property: craft\feedme\events\FieldEvent::isValid - BaseObject.php: 163`?  
> **username_1**: Is this in relation to your bountied post? If I understood correctly, I don’t think it’s doable with Feed Me as it is.  
> **username_1**: And in relation to this question, isValid is not available on this event.  

---

