Bukimedia / PrestaSharp

CSharp .Net client library for the PrestaShop API via web service
GNU General Public License v3.0
154 stars 152 forks source link

Add head functionality in Generic Factory and Image Factory #462

Closed sanctusmob closed 7 months ago

sanctusmob commented 1 year ago

You can check if ID exists for entities and for images via head request.

ex. blExists = manufacturerFactory.CheckIfExists(lngManufacturerID); blExists = productFactory.CheckIfExists(lngProductID); blExists = imageFactory.CheckIfExistsCategoryImage(lngCategoryID); blExists = imageFactory.CheckIfExistsManufacturerImage(lngManufacturerID); blExists = imageFactory.CheckIfExistsProductImage(lngProductID, lngImageID); blExists = imageFactory.CheckIfExistsProductImage(lngProductID, null);

LameuleFR commented 7 months ago

Hi @sanctusmob

I approve this PR. Cool & efficient idea to check if an entity exists using the HEAD method LGTM🚀