MCPcopy Create free account
hub / github.com/Rello/analytics / deleteByUser

Method deleteByUser

lib/Service/PanoramaService.php:216–223  ·  view source on GitHub ↗

* get dataset by user * * @param string $userId * @return array|bool * @throws Exception */

(string $userId)

Source from the content-addressed store, hash-verified

214 * @throws Exception
215 */
216 public function deleteByUser(string $userId) {
217 $panoramas = $this->PanoramaMapper->indexByUser($userId);
218 foreach ($panoramas as $panorama) {
219 $this->ShareService->deleteSharesByItem(ShareService::SHARE_ITEM_TYPE_PANORAMA, $panorama['id']);
220 $this->setFavorite($panorama['id'], 'false');
221 }
222 return $this->PanoramaMapper->deleteByUser($userId);
223 }
224
225 private function isValidParent(int $parentId, ?int $itemId = null): bool {
226 if ($parentId === 0) {

Callers

nothing calls this directly

Calls 3

setFavoriteMethod · 0.95
indexByUserMethod · 0.45
deleteSharesByItemMethod · 0.45

Tested by

no test coverage detected