It seems too many people misunderstand the idea of kindness. Kindness isn't being nice to someone for something in return. Kindness is being nice. Period. Whether it's reciprocated or not is irrelevant to the matter.
Kindness is also who you are as a person. So you cannot one minute be nice to someone and the next minute not be nice to someone else. To me that isn't kindness.
And even though you were careful, should you have been taken advantaged of because of your kindness then it's ok. Because being nice is its own reward, you have already gained.
Life is full of refinement in behavior. Being prudent is wise. But if there was ever a default position, it is to begin with kindness. ☮