【问题标题】:Dropbox SDK - Swift - (415) Unsupported Media TypeDropbox SDK - Swift - (415) 不支持的媒体类型
【发布时间】:2016-01-24 07:15:40
【问题描述】:

我在我的 iOS swift 应用中使用 DropboxSDK,当我尝试下载缩略图时收到 (415) Unsupported Media Type 错误:

2015-10-24 20:10:23.732 PhotondRoll[55084:2520699] [警告] DropboxSDK:向 /1/thumbnails/dropbox/Pictures/2015/0123 发出请求时出错。 Noche de cine con Pablo/20150123_211742443_iOS.jpg - (415) 不支持的媒体类型

这是我用来下载缩略图的行。其余代码是按照 Dropbox 入门指南创建的。

if let dirs : [String] = NSSearchPathForDirectoriesInDomains(NSSearchPathDirectory.DocumentDirectory, NSSearchPathDomainMask.AllDomainsMask, true) {
    let dir = dirs[0] //documents directory
    dropboxRestClient.loadThumbnail(metadata.path, ofSize: "s", intoPath: dir)
}

你能帮帮我吗?

【问题讨论】:

标签: ios swift sdk thumbnails dropbox


【解决方案1】:

我能够在 dispatch_async 块内移动 loadThumbnail 调用来解决这个问题。

【讨论】:

    猜你喜欢
    • 2014-05-10
    • 2019-05-01
    • 2017-06-30
    • 2017-07-05
    • 2016-11-26
    • 2015-08-21
    • 2015-08-29
    相关资源
    最近更新 更多