def initialize(user)
can [:relation, :relation_history, :way, :way_history, :node, :node_history, :changeset, :note], :browse
can :index, ChangesetComment
+ can :search, :direction
can [:index, :permalink, :edit, :help, :fixthemap, :offline, :export, :about, :preview, :copyright, :key, :id], :site
can [:index, :rss, :show, :comments], DiaryEntry
can [:finish, :embed], :export
before_action :authorize_web
before_action :set_locale
before_action :require_oauth, :only => [:search]
+ authorize_resource :class => false
def search
render :layout => map_layout