Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shared file notifications #12608

Closed
Ar1anna opened this issue Dec 4, 2014 · 4 comments
Closed

Shared file notifications #12608

Ar1anna opened this issue Dec 4, 2014 · 4 comments
Labels

Comments

@Ar1anna
Copy link

Ar1anna commented Dec 4, 2014

Following issue #4499 everything works fine if the file is shared with a single user or a group with users that are only in that group.

When users are in multiple groups notification fail: the email doesn't contain che file name.

The problem is in lib/private/share/share.php file:
$result = \OC_DB::executeAudited($query, array($itemSource, $itemType, implode(',', $groups)));

Parameters to the query $query = \OC_DB::prepare(
'SELECT file_target, permissions, expiration
FROM
*PREFIX*share
WHERE
item_source = ? AND item_type = ? AND share_with in (?)'
);

are correct (i tryed executing it via sql prompt) but malformed, I suppose.
I don know how to get rid of it.

Any help?
A.

@nickvergessen
Copy link
Contributor

Please use the issue template for reporting bugs:
https://raw.githubusercontent.com/owncloud/core/master/issue_template.md

@Ar1anna
Copy link
Author

Ar1anna commented Dec 4, 2014

Steps to reproduce

  1. share a file with group A
  2. users in group A are also in group B and C

Expected behaviour

Users should receive an email containing the file name and a link to the shared file (Arianna shared »Shared/File_name« with you)

Actual behaviour

Users receive an email without file name. The link point to nothing. (Arianna shared »« with you)

Server configuration

Operating system: Centos 6
Web server: Apache
Database: Mysql
PHP version: PHP 5.4.32
ownCloud version: 7.0.2 (stable)
Updated from an older ownCloud or fresh install: updated from 6
List of activated apps: Calendar, Activity
The content of config/config.php:
$CONFIG = array (
'theme' => 'unimibox',
'instanceid' => '530f33789e9ca',
'passwordsalt' => ',
'datadirectory' => '/app/home/owncloud/data',
'dbtype' => 'mysql',
'version' => '7.0.2.1',
'dbname' => 'owncloud',
'dbhost' => 'localhost',
'dbtableprefix' => 'oc_',
'dbuser' => 'oc_admin',
'dbpassword' => '',
'installed' => true,
'logfile' => '/var/log/owncloud/own.log',
'loglevel' => '0',
'cron_log' => true,
'log_rotate_size' =>10 * 1024 * 1024,
'logdateformat' => 'F d, Y H:i:s',
'logtimezone' => 'Europe/Berlin',
'ldapIgnoreNamingRules' => false,
"session_lifetime" => 60 * 31 * 1,
"remember_login_cookie_lifetime" => 60_31_1*1,
'mail_smtpmode' => 'smtp',
'mail_smtphost' => 'smtp.mydomain',
'mail_smtpport' => 25,
"mail_smtpdebug" => true,
'default_language' => 'it',
'maintenance' => false,
'trusted_domains' =>
array (
0 => 'owncloud02.divsi.unimi.it',
),
'share_folder' => '/Shared',
);

Are you using external storage, if yes which one: nfs
Are you using encryption: no

Client configuration

Browser: Firefox
Operating system: centos 6

Logs

ownCloud log (data/owncloud.log)

{"reqId":"547f23b7d651c","app":"PHP","message":"Undefined offset: 0 at /app/home/owncloud/lib/private/share/mailnotifications.php#90","level":3,"time":"December 03, 2014 15:52:39","method":"POST","url":"/index.php/core/ajax/share.php"}
{"reqId":"547f23b7d651c","app":"mail","message":"Mail from Arianna ([email protected]) to: Matteo (xxxx@xxx) subject: Arianna shared \u00bb\u00ab with you","level":0,"time":"December 03, 2014 15:52:39","method":"POST","url":"/index.php/core/ajax/share.php"}

@nickvergessen
Copy link
Contributor

Duplicate of #11808

@Ar1anna
Copy link
Author

Ar1anna commented Dec 4, 2014

ok, thank you very much!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants