convert to sinatra