Based on the vector magnetograms obtained from the SDO/HMI, we calculate the line-of-sight current density distribution of the active region on 2017 September 6, using the integral form of Ampere's law. Comparing the distribution of the current density and the observed flare, we find that: Firstly, the changing trend of the total current density of the active region was consistent with the change of the X-ray flux of the X9.3 flare. Secondly, the distribution of the double-ribbon flare was co-spatial with a pair of conjugate current ribbons with opposite polarities, which were consistently located on both sides of the Line-of line. Additionally, these current ribbons exhibit significant and continuous changes during the flare eruption: During the early phase of the flare eruption, there was a substantial decrease in the area of the current ribbons, resulting in the emergence of a series of high-density small current islands. During the later phase, not only the area rapidly increases, but the flare kernel evolves into a the flare band with the full release of energy. We have discovered a strong spatial correspondence between the flare kernel and the current islands through positional comparisons. This process is consistent with the physical phenomenon of the current pinch effect. Therefore, we speculate that a current pinch effect may occur during the flare eruption, and the formation of the flare kernel is likely attributed to the current pinch effect.