# Liquid assign\_to

**URL:** <https://www.ruby-forum.com/t/liquid-assign-to/175552>\
**Category:** Rails\
**Created:** [September 15, 2009, 2:32pm UTC](https://www.ruby-forum.com/t/liquid-assign-to/175552 "2009-09-15T14:32:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![pubclub](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/p/3d9bf3/32.png) [@pubclub](https://www.ruby-forum.com/u/pubclub)\
**Post date:** [September 15, 2009, 2:32pm UTC](https://www.ruby-forum.com/t/liquid-assign-to/175552/1 "2009-09-15T14:32:09Z")

</div>

Hello using liquid markup i am trying to do the following.

{{ ‘holiday’ | album\_thumbs | assign\_to ‘asset\_list’ }}

{% for asset in asset\_list %}  
"link: " + {{ asset | asset\_path }}  
{% endfor %}

It should return a list with all assets for the loop, but the asset\_list  
variable never gets set. It just returns #### (number of records) on  
this line:

{{ ‘holiday’ | album\_thumbs | assign\_to ‘asset\_list’ }}

I have created the following function inside a (drop) filter

def album\_thumbs(tag)  
@context[‘domain’].find\_assets\_tagged\_with(tag)  
end

I am using Liquid 1.9.0 on rails 2.2.2
