It depends on the terrain, but generally what others said - brake before the turn.
When in the turn, weight the *front* wheel more than the back - front wheel traction is more important because it dictates which direction you are going. Lost front wheel traction (esp at speed) can lead to wipeouts no matter which brake you're using. If there's a good enough berm, lean into the turn, look ahead, lay off the brakes and the bike will follow.