SB 8.12.31

tasyāsau padavīṁ rudro
 viṣṇor adbhuta-karmaṇaḥ
pratyapadyata kāmena
 vairiṇeva vinirjitaḥ
Synonyms: 
tasya — of He who is the Supreme Lord; asau — Lord Śiva; padavīm — the place; rudraḥ — Lord Śiva; viṣṇoḥ — of Lord Viṣṇu; adbhuta-karmaṇaḥ — of He who acts very wonderfully; pratyapadyata — began to follow; kāmena — by lusty desire; vairiṇā iva — as if by an enemy; vinirjitaḥ — being harassed.
Translation: 
As if harassed by an enemy in the form of lusty desires, Lord Śiva followed the path of Lord Viṣṇu, who acts very wonderfully and who had taken the form of Mohinī.
Purport: 

Lord Śiva cannot be victimized by māyā. Therefore it is to be understood that Lord Śiva was being thus harassed by Lord Viṣṇu’s internal potency. Lord Viṣṇu can perform many wonderful activities through His various potencies.

parāsya śaktir vividhaiva śrūyate
 svābhāvikī jñāna-bala-kriyā ca

(Śvetāśvatara Upaniṣad 6.8)

The Supreme Lord has various potencies, by which He can act very efficiently. To do anything expertly, He doesn’t even need to contemplate. Since Lord Śiva was being harassed by the woman, it is to be understood that this was being done not by a woman but by Lord Viṣṇu Himself.