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

[stable13] Fix local users check in contacts menu #9732

Merged
merged 2 commits into from Jun 4, 2018

Conversation

@ChristophWurst
Member

ChristophWurst commented Jun 4, 2018

Backport of #9725

Fix local users check in contacts menu
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>

@ChristophWurst ChristophWurst added this to the Nextcloud 13.0.3 milestone Jun 4, 2018

@ChristophWurst ChristophWurst self-assigned this Jun 4, 2018

@ChristophWurst ChristophWurst added this to SELECTED in Christoph's Tasks via automation Jun 4, 2018

@ChristophWurst ChristophWurst requested review from rullzer and MorrisJobke Jun 4, 2018

@ChristophWurst ChristophWurst moved this from SELECTED to TO REVIEW (max 4 PRs) in Christoph's Tasks Jun 4, 2018

@@ -202,7 +202,8 @@ public function findOne(IUser $user, $shareType, $shareWith) {
}
}
if ($shareType === 0 || $shareType === 6) {
if ($contact['UID'] === $shareWith && $contact['isLocalSystemBook'] === true) {
$isLocal = $contact['isLocalSystemBook'] ?? false;

This comment has been minimized.

@MorrisJobke

MorrisJobke Jun 4, 2018

Member

PHP 7.0+ only operator 😉 Use this instead:

$isLocal = isset($contact['isLocalSystemBook']) ? $contact['isLocalSystemBook'] : false;

This comment has been minimized.

@MorrisJobke

MorrisJobke Jun 4, 2018

Member

And CI would have catched this 🚀 🙌 https://drone.nextcloud.com/nextcloud/server/7709/90

Fix syntax for php5.6
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
@codecov

This comment has been minimized.

codecov bot commented Jun 4, 2018

Codecov Report

Merging #9732 into stable13 will increase coverage by <.01%.
The diff coverage is 100%.

@@              Coverage Diff               @@
##             stable13    #9732      +/-   ##
==============================================
+ Coverage       51.44%   51.44%   +<.01%     
- Complexity      25130    25131       +1     
==============================================
  Files            1613     1613              
  Lines           95617    95618       +1     
  Branches         1376     1376              
==============================================
+ Hits            49188    49190       +2     
+ Misses          46429    46428       -1
Impacted Files Coverage Δ Complexity Δ
...ib/private/Contacts/ContactsMenu/ContactsStore.php 86.13% <100%> (+0.13%) 42 <0> (+1) ⬆️
apps/files_trashbin/lib/Trashbin.php 72.53% <0%> (+0.24%) 136% <0%> (ø) ⬇️
@rullzer

rullzer approved these changes Jun 4, 2018

@MorrisJobke MorrisJobke merged commit e656c8e into stable13 Jun 4, 2018

4 checks passed

codecov/patch 100% of diff hit (target 51.44%)
Details
codecov/project 51.44% (+<.01%) compared to 778c411
Details
continuous-integration/drone/pr the build was successful
Details
continuous-integration/drone/push the build was successful
Details

Christoph's Tasks automation moved this from TO REVIEW (max 4 PRs) to DONE Jun 4, 2018

@rullzer rullzer deleted the stable13-fix-contacts-menu-local-null-check branch Jun 4, 2018

@MorrisJobke MorrisJobke referenced this pull request Jun 4, 2018

Merged

13.0.3 RC 2 #9731

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment