IIRC They had had a hard landing which cracked part of the main gear structure, I think the crew reported the hard landing and the onboard QAR recorded it also. Nothing was found during the required maintenance checks however, on the next departure, the gear failed to retract and so they returned at which point the damage was found following a further inspection.
It is not particularly unusual that a 'failure to retract' defect is traced to a warped/bent/broken or otherwise deteriorated component in the shock strut, causing the strut to not fully extend after T/O. The gear position/proximity sensors detect the imperfect geometry and refuse to allow the gear to retract thereby preventing potential secondary issues, like fouling of the gear on structure during retraction.