Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions content/php/beginner/3.md
Original file line number Diff line number Diff line change
Expand Up @@ -264,10 +264,10 @@ Also notice we're *not* adding this to `routes.php` — the `#[FrontpageRoute]`

```bash
# Run from: ~/nextcloud-docker-dev/
./scripts/occ.sh nextcloud -- router:list | grep pinboard
./scripts/occ.sh nextcloud -- router:list pinboard
```

You should see both `pinboard.page.index` and `pinboard.page.get_pins` listed.
`router:list` takes an app ID, so you get just your app's routes without having to filter the full list. You should see both `pinboard.page.index` and `pinboard.page.get_pins` listed.

---

Expand Down Expand Up @@ -328,15 +328,21 @@ Expected response: `[]` — `JSONResponse` returns your data directly without an

```bash
# Run from: ~/nextcloud-docker-dev/
./scripts/occ.sh nextcloud -- router:list | grep pinboard
./scripts/occ.sh nextcloud -- router:list pinboard
```

You should see at minimum:
```
pinboard.page.index GET /index.php/apps/pinboard/
pinboard.page.get_pins GET /index.php/apps/pinboard/pins
+------------------------+---------+-------------------------------+
| route | request | path |
+------------------------+---------+-------------------------------+
| pinboard.page.get_pins | GET | /index.php/apps/pinboard/pins |
| pinboard.page.index | GET | /index.php/apps/pinboard/ |
+------------------------+---------+-------------------------------+
```

Routes are listed alphabetically by name, so `get_pins` comes before `index`.

---

## Common problems
Expand Down