Commit 19b8249e authored by Albert Vaca Cintora's avatar Albert Vaca Cintora
Browse files

Changes as per CR

parent 58adbc8c
Pipeline #147870 passed with stage
in 3 minutes and 3 seconds
......@@ -203,12 +203,12 @@ void SharePlugin::shareUrl(const QUrl& url, bool open)
NetworkPacket packet(PACKET_TYPE_SHARE_REQUEST);
if (url.isLocalFile()) {
QSharedPointer<QFile> ioFile(new QFile(url.toLocalFile()));
QFileInfo info(*ioFile);
if (!ioFile->exists()) {
Daemon::instance()->reportError(i18n("Could not share file"), i18n("%1 does not exist", url.toLocalFile()));
} else {
QFileInfo info(*ioFile);
packet.setPayload(ioFile, ioFile->size());
packet.set<QString>(QStringLiteral("filename"), QUrl(url).fileName());
packet.set<qint64>(QStringLiteral("creationTime"), info.birthTime().toMSecsSinceEpoch());
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment