# \[Solved\] Why won’t my loop evaluate this logic?

**URL:** https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452
**Category:** Questions about Thunkable X
**Tags:** solved
**Created:** [March 23, 2020, 9:59pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452 "2020-03-23T21:59:02Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![athornock](https://avatars.discourse-cdn.com/v4/letter/a/b4bc9f/32.png) [@athornock](https://community.thunkable.com/u/athornock)
#### Post date: [March 23, 2020, 9:59pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/1 "2020-03-23T21:59:02Z")

</div>

Hi guys,  
I’ve searched for this behavior, but can’t find anything about it specifically.

Since there’s not a way to delete properties in a nested object. I’m trying to reset the property (which is itself an object) and then rebuild the object without that specific nested object in it. I’ve tried the blocks a few different ways, but I can’t get Thunkable to evaluate the nested property (the circled blocks).

 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/1/6/169e170095d7bbd6e71bcc06d4f152f5a1a8b3bb.png)

As you can see above it I tried building a list of that property and show it in a test label below. The list does not show the changed property “delete”, however, if I view the JSON of the full object (where the arrow is) I can see the property with an object of {“for”:“delete”}.

Since I can’t get Thunkable to evaluate that property I can’t delete it out of the object and re-upload it to firebase.

Any work arounds?

---

<div class="post-metadata">

### Author: ![jared](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jared/32/138473_2.png) [@jared](https://community.thunkable.com/u/jared)
#### Post date: [March 23, 2020, 10:03pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/2 "2020-03-23T22:03:10Z")

</div>

Hey @athornock, good question!

Try using the text blocks for the logic

`If Does text (object) contain text “false” Then continue with next iteration of loop Else //don’t change your code here`

---

<div class="post-metadata">

### Author: ![athornock](https://avatars.discourse-cdn.com/v4/letter/a/b4bc9f/32.png) [@athornock](https://community.thunkable.com/u/athornock)
#### Post date: [March 23, 2020, 10:10pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/3 "2020-03-23T22:10:58Z")

</div>

Stellar thought. It’s not working either though:

 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/8/0/80884e5cc5a67eb1075162498ee52e459cbf00cb.png)

---

<div class="post-metadata">

### Author: ![jared](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jared/32/138473_2.png) [@jared](https://community.thunkable.com/u/jared)
#### Post date: [March 23, 2020, 10:30pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/4 "2020-03-23T22:30:16Z")

</div>

first potential issue.  
this code returns whatever is within that object. probably some text

 ![Screen Shot 2020-03-23 at 6.11.14 PM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/8/c/8cdcfbf3df6230588dff044a78c352e9dbf056b8.png)

but this code returns either ‘true’ or ‘false’

 ![Screen Shot 2020-03-23 at 6.11.21 PM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/a/b/abe9483c86c7f66b9fed81bebb7ae04d650872bb.png)

i wonder if this returns a list

 ![Screen Shot 2020-03-23 at 6.12.50 PM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/f/6/f60e830ac63830c66e232128840d94762ee9fee1.png)

what i meant was something more like this  
 ![Screen Shot 2020-03-23 at 6.15.50 PM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/e/2/e268d9bede248756297fb3e2945b78e3cdebf669.png)

---

<div class="post-metadata">

### Author: ![athornock](https://avatars.discourse-cdn.com/v4/letter/a/b4bc9f/32.png) [@athornock](https://community.thunkable.com/u/athornock)
#### Post date: [March 23, 2020, 11:14pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/5 "2020-03-23T23:14:18Z")

</div>

That method crashes the app altogether:  
 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/0/f/0f246ef4d74b9061a3d74a7d842c5e02f6873186.png)

---

<div class="post-metadata">

### Author: ![manyone](https://avatars.discourse-cdn.com/v4/letter/m/ee59a6/32.png) [@manyone](https://community.thunkable.com/u/manyone)
#### Post date: [March 23, 2020, 11:25pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/6 "2020-03-23T23:25:37Z")

</div>

have you tried setting that (get property “for”…) to a temporary app var first then plug THAT in place - in both the insert last, and in the following IF statement?

---

<div class="post-metadata">

### Author: ![athornock](https://avatars.discourse-cdn.com/v4/letter/a/b4bc9f/32.png) [@athornock](https://community.thunkable.com/u/athornock)
#### Post date: [March 23, 2020, 11:46pm UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/7 "2020-03-23T23:46:43Z")

</div>

That was a good idea. That seems to have worked:

 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/c/a/cadf4448a53abbf1bddc91c7b49b4834064216cc.png)

---

<div class="post-metadata">

### Author: ![jared](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jared/32/138473_2.png) [@jared](https://community.thunkable.com/u/jared)
#### Post date: [March 24, 2020, 1:00am UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/8 "2020-03-24T01:00:56Z")

</div>

So with var app list, in your loop, you want a list of true or false, correct?

I’m glad your code is working now!

---

<div class="post-metadata">

### Author: ![athornock](https://avatars.discourse-cdn.com/v4/letter/a/b4bc9f/32.png) [@athornock](https://community.thunkable.com/u/athornock)
#### Post date: [March 24, 2020, 2:07am UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/9 "2020-03-24T02:07:22Z")

</div>

Yes, basically.  
Thanks for all your help!

---

<div class="post-metadata">

### Author: ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)
#### Post date: [November 8, 2024, 11:39am UTC](https://community.thunkable.com/t/solved-why-won-t-my-loop-evaluate-this-logic/531452/10 "2024-11-08T11:39:43Z")

</div>


