# Week 4
Hi everyone, Rupam here. As I said in my update last week, I was yet to debug the already existing light client implementation in Prysm. This week I opened a PR for the same and another PR which implements the ``is_better_update`` helper function from [CL specs](https://github.com/ethereum/consensus-specs/blob/dev/specs/altair/light-client/sync-protocol.md#is_better_update).
## Some Existing Errors
The following errors were pointed out by [rkapka](https://github.com/rkapka)
1. This is not needed, we don't want to skip the update
```
// Let's not use the first slot in the period, otherwise the attested header will be in previous period
firstSlotInPeriod++
```
2. We should return an error in such scenarios, not silently continue. This has nothing to do with the update being available, if there is an error here then we might have a bug that should be fixed
```
state, err = s.Stater.StateBySlot(ctx, types.Slot(slot))
if err != nil {
continue
}
```
3. One vote is enough, the 2/3 constraint is not required
```
if syncAggregate.SyncCommitteeBits.Count()*3 < config.SyncCommitteeSize*2 {
// Not enough votes
continue
}
```
In the 3rd error, required unit tests were needed to be added too, one for 0 votes and another for 1 vote.
All of the above errors have been addressed in this [PR](https://github.com/prysmaticlabs/prysm/pull/14171).
## ``is_better_update`` Implementation
This [PR](https://github.com/prysmaticlabs/prysm/pull/14186) implements the ``is_better_update`` helper function from CL specs. I also had to implement 2 smaller helper functions ``is_finality_update`` and ``is_sync_committee_update`` in the same PR as they are used by the ``is_better_update`` function. I am yet to add the unit tests for this one in the same PR or in another one depending on what Radek says.
## Some other references
* https://github.com/prysmaticlabs/prysm/issues/14170
* https://github.com/prysmaticlabs/prysm/issues/14185