ANSWER:

How do you know that she did not intend Allah’s pleasure in this?

And it was a dog and not a cat.

QUESTION: I know that goods deeds are only accepted when we intend for doing it for the sake of Allah but then a story comes to my mind of a girl who was passing by a street and she feeds a hungry or thrusty cat and she was forgiven by this action. But this girl did not feed the cat by the intention of pleasing Allah .