lib/google/cloud/storage/file.rb in google-cloud-storage-0.20.1 vs lib/google/cloud/storage/file.rb in google-cloud-storage-0.20.2
- old
+ new
@@ -11,10 +11,11 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
+require "uri"
require "google/cloud/storage/file/acl"
require "google/cloud/storage/file/list"
require "google/cloud/storage/file/verifier"
module Google
@@ -735,10 +736,10 @@
end
##
# The external path to the file.
def ext_path
- "/#{@file.bucket}/#{@file.name}"
+ URI.escape "/#{@file.bucket}/#{@file.name}"
end
##
# The external url to the file.
def ext_url