| @@ 129-135 (lines=7) @@ | ||
| 126 |     { | 
                                |
| 127 |         $node = Models\Node::where('id', $id); | 
                                |
| 128 | ||
| 129 |         if (! is_null($request->input('fields'))) { | 
                                |
| 130 |             foreach (explode(',', $request->input('fields')) as $field) { | 
                                |
| 131 |                 if (! empty($field)) { | 
                                |
| 132 | $node->addSelect($field);  | 
                                |
| 133 | }  | 
                                |
| 134 | }  | 
                                |
| 135 | }  | 
                                |
| 136 | ||
| 137 |         try { | 
                                |
| 138 |             if (! $node->first()) { | 
                                |
| @@ 106-112 (lines=7) @@ | ||
| 103 |     { | 
                                |
| 104 |         $query = Models\Server::where('id', $id); | 
                                |
| 105 | ||
| 106 |         if (! is_null($request->input('fields'))) { | 
                                |
| 107 |             foreach (explode(',', $request->input('fields')) as $field) { | 
                                |
| 108 |                 if (! empty($field)) { | 
                                |
| 109 | $query->addSelect($field);  | 
                                |
| 110 | }  | 
                                |
| 111 | }  | 
                                |
| 112 | }  | 
                                |
| 113 | ||
| 114 |         try { | 
                                |
| 115 |             if (! $query->first()) { | 
                                |
| @@ 80-86 (lines=7) @@ | ||
| 77 |     { | 
                                |
| 78 |         $query = Models\User::where('id', $id); | 
                                |
| 79 | ||
| 80 |         if (! is_null($request->input('fields'))) { | 
                                |
| 81 |             foreach (explode(',', $request->input('fields')) as $field) { | 
                                |
| 82 |                 if (! empty($field)) { | 
                                |
| 83 | $query->addSelect($field);  | 
                                |
| 84 | }  | 
                                |
| 85 | }  | 
                                |
| 86 | }  | 
                                |
| 87 | ||
| 88 |         try { | 
                                |
| 89 |             if (! $query->first()) { | 
                                |