S
S
Stanislav2016-07-14 22:05:03
Node.js
Stanislav, 2016-07-14 22:05:03

Why doesn't the file upload to Yandex Disk?

Guys, I don’t understand what’s wrong, I ask for help.
You need to upload the file to the Yandex disk, I took
npm for this https://github.com/Kolyaj/yandex-disk
I write like this

var YandexDisk    = require('yandex-disk').YandexDisk;

var disk = new YandexDisk('login', 'password');

disk.uploadFile('/var/www/file_image.jpg', '/', function(e) {

    console.log(e);

});

The file is not loading and there are no errors, what could be the problem?
I tried to create folders on the disk, they are created, but the file does not upload to them =(

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
Eugene, 2016-07-14
@Nc_Soft

curl --user USER:PASSWORD -T "/path/to/file" https://webdav.yandex.ru/

#
#algooptimize #bottize, 2016-07-15
@user004

_request: function(method, path, headers, body, responseType, callback) {
set a breakpoint and see.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question