aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/database/DeviceManager.java
diff options
context:
space:
mode:
authorAbyss777 <abyss@fox5.ru>2017-01-16 16:27:51 +0500
committerAbyss777 <abyss@fox5.ru>2017-01-16 16:34:31 +0500
commit8a19ed9994e6bdd531faa3021711fc0e89497ca8 (patch)
treefa53e0b262be74b3bf4dd429219a4e20236493c9 /src/org/traccar/database/DeviceManager.java
parentb5eb48cbba215ca55c1a5e5ae5fae5b375243247 (diff)
downloadtrackermap-server-8a19ed9994e6bdd531faa3021711fc0e89497ca8.tar.gz
trackermap-server-8a19ed9994e6bdd531faa3021711fc0e89497ca8.tar.bz2
trackermap-server-8a19ed9994e6bdd531faa3021711fc0e89497ca8.zip
- Rename otherUserId to managedUserId
- Optimize getManaged* functions
Diffstat (limited to 'src/org/traccar/database/DeviceManager.java')
-rw-r--r--src/org/traccar/database/DeviceManager.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/org/traccar/database/DeviceManager.java b/src/org/traccar/database/DeviceManager.java
index bcb3185ca..8e75903db 100644
--- a/src/org/traccar/database/DeviceManager.java
+++ b/src/org/traccar/database/DeviceManager.java
@@ -163,8 +163,8 @@ public class DeviceManager implements IdentityManager {
public Collection<Device> getManagedDevices(long userId) throws SQLException {
Collection<Device> devices = new ArrayList<>();
devices.addAll(getDevices(userId));
- for (long otherUserId : Context.getPermissionsManager().getUserPermissions(userId)) {
- devices.addAll(getDevices(otherUserId));
+ for (long managedUserId : Context.getPermissionsManager().getUserPermissions(userId)) {
+ devices.addAll(getDevices(managedUserId));
}
return devices;
}
@@ -301,8 +301,8 @@ public class DeviceManager implements IdentityManager {
public Collection<Group> getManagedGroups(long userId) throws SQLException {
Collection<Group> groups = new ArrayList<>();
groups.addAll(getGroups(userId));
- for (long otherUserId : Context.getPermissionsManager().getUserPermissions(userId)) {
- groups.addAll(getGroups(otherUserId));
+ for (long managedUserId : Context.getPermissionsManager().getUserPermissions(userId)) {
+ groups.addAll(getGroups(managedUserId));
}
return groups;
}