Thompson was originally arrested on robbery charges.
A spokesman for the Staten Island DA says when he showed up at Richmond County Criminal Court, he posed as another defendant.
The judge accepted a guilty plea under those false pretences and sentenced him to time served.
After getting a sentence of time served, Thompson was set free before anyone realized what had happened.
The officer who failed to properly check his ID has been placed on modified assignment.