Help with routes

In my view, I’ve got the following condition:

<% if current_page? :controller => ‘deals’, :action => ‘foobar’ %>
woot
<% end %>

My route looks like:

map.fobar ‘/:city.:format’, :controller => ‘deals’, :action =>
‘foobar’, :defaults => { :format => ‘html’ }

However, the conditions succeeds if I do:

<%= active_if { current_page? :controller => ‘deals’, :action =>
‘todays_deal’, :format => ‘html’ } %>

Why do I need to pass :format => ‘html’?

On another page I have:

route: map.resources :deals

<%= if current_page? :controller => ‘deals’, :action => ‘index’ %>,
without :format => ‘html’, the condition also succeeds.

So why is it failing with deals#foobar ?