mirror of
https://github.com/servo/servo
synced 2026-05-13 10:27:03 +02:00
Renames local variable `worker` to `worker_actor` in `lib.rs` and
`root.rs`, following the `{}_actor` convention for actor struct
variables and `{}_name` for actor name string variables established in
#43606.
Also adds a `WorkerActor::register()` method (part of #43800), replacing
the inline struct construction in `lib.rs` with a consistent pattern
pattern matching other actors like `ThreadActor` and `SourceActor`.
**Changes:**
- `actors/worker.rs`: Add `WorkerActor::register()` method
- `actors/root.rs`: Rename `worker` → `worker_actor` in
`listServiceWorkerRegistrations` handler
- `lib.rs`: Replace inline struct construction with
`WorkerActor::register()` call
**Testing:** No testing required, compiles successfully.
Fixes: Part of #43606
Fixes: Part of #43800
Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>