If you’re not subscribed and your friend code isn’t currently whitelisted, seeing an error is expected in all Pokémon games.