The get methods for several color objects in the Spreadsheet Service have been deprecated | Release Notes | March 18, 2022 | Apps Script | Google Developers
The get methods for several color objects in the Spreadsheet Service have been deprecated in favor of a new naming convention. The functionality remains the same. For example, the getFontColor() method from the Range class has been replaced with getFontColorObject().
Check out the source link for details of which Spreadsheet Services have been updated.