Is that a recent law? I have a few friends, one of who used to work for an electric bike manufacturer, and they can get up to 35mph on their electric bikes. But that was from a few years ago.
Not very recent, no. But it is an easy hack to bypass the limits... just tell your controller you have a different wheel size. So it could very well be that your friends are simply speeding.