# PersonEmailController

**Kind:** Controller

**Source:** `Pams/API/Pams.API/Controllers/Person/PersonEmailController.cs` (line 22)

**Part of:** [Pams](subsystem-pams)

## Where it refuses work

- `PersonEmailController` stops the work with an early return when `!ModelState.IsValid`, in 2 places.
- `PersonEmailController` stops the work with an early return when `!mail.Save()`, in 2 places.
- `PersonEmailController` stops the work with an early return when `!eml.HasObject`.
- `PersonEmailController` stops the work with an early return when `!eml.Delete()`.

## When something fails

- `PersonEmailController` handles failure in 8 places: it turns it into a return value in all 8.

## Relationships

- MODULE_DECLARES → `GetByPersonID`
- MODULE_DECLARES → `insert`
- MODULE_DECLARES → `update`
- MODULE_DECLARES → `delete`
- IMPORTS → `Person`
- IMPORTS → `PersonEmail`
- IMPORTS → `BaseController`
- IMPORTS → `Employee`
- IMPORTS → `GetByPersonID`
- IMPORTS → `GetByPersonID`
- IMPORTS → `Save`

## Used by

3 references from 3 files. Each is a place in this repository where the symbol is actually used — go read one rather than trusting an example.

### calls by (3)

- `AppSettings` — `Frontend/src/app/settings/app/app.settings.ts`:241
- `AppSettings` — `Pams/Web/Pams.Web/Client/app/settings/app/app.settings.ts`:126
- `AppSettings` — `Pams/Web/Pams.WebApp/Client/app/settings/app/app.settings.ts`:6
