tweaked Resource.__uri__ to allow None