We present a novel treatment for calculating the in-medium quark condensates. The advantage of this approach is that one does not need to make further assumptions on the derivatives of model parameters with respect to the quark current mass. The normally accepted model-independent result in nuclear matter is naturally reproduced. The change of the quark condensate induced by interactions depends on the incompressibility of nuclear matter. When it is greater than 260 MeV, the density at which the condensate vanishes is higher than that from the linear extrapolation. For the chiral condensate in quark matter, a similar model-independent linear behavior is found at lower densities, which means that the decreasing speed of the condensate in quark matter is merely half of that in nuclear matter if the pion-nucleon sigma commutator is six times the average current mass of u and d quarks. The modification due to QCD-like interactions is found to slow the decreasing speed of the condensate, compared with the linear extrapolation.