If you'd be veering into traffic to avoid an object you may be riding too close to the curb. If it's a large object that comes all the way from the curb to the right tire track, then I suppose you can check your mirror, stop if needed. Anything that large shouldn't be a surprise and you should have plenty of time to plan avoidance.
If it's smaller than that, then if there's a car close, go around it on the right.
If there's no room to the right, then you're riding too far right.
__________________
Work: the 8 hours that separates bike rides.