diff --git a/_posts/2023-03-21-web-workers-in-angular.md b/_posts/2023-03-21-web-workers-in-angular.md index 8e8ed66..b8491de 100644 --- a/_posts/2023-03-21-web-workers-in-angular.md +++ b/_posts/2023-03-21-web-workers-in-angular.md @@ -241,7 +241,7 @@ Check your devtools console and try clicking the buttons to see what's happening If you see this, your app is now creating and using a web worker. -👨🏻‍💻 Now update the `sortHeroes` method so that it will call `worker.postMessage` with the received `flag` argument. +👨🏻‍💻 Now update the `sortHeroes` method so that it will call `worker.postMessage` with an object containing `heroes` and the received `flag` argument. 👨🏻‍💻 Also, update the `worker.onmessage` callback so that it will assign the processed data to `this.heroes`.