millermedeiros/crossroads.js — pull request #76 by Zav39 (2012-12-18 11:23:18+00:00)
Title: Interpolate fix: now possible to pass object for :?query: instead of string

The Problem
------------------
We have route
```
var a = crossroads.addRoute('/{foo}/:?query:');
```
When we get matched signal, it return query {object}, but when we try to interpolate this route, we need to pass '?query' string, what is strange. We must able to write something like this:
```
a.interpolate({foo: 'dolor-sit', query: {multiple: 'params', works: 'fine'}})
```

The Solution
-----------------
Check first letter for '?' symbol and, if object was passed, transpose object to string.