This section applies where—
This section also applies where—
The local authority concerned may recover from the other local authority the amount of any payments it made towards meeting the needs in question at a time when the other local authority was instead liable to meet them under section 18 or 20(1) (as the case may be).
Subsection (3) does not apply to payments which are the subject of a deferred payment agreement entered into by the local authority in question, unless it agrees with the other local authority to assign its rights and obligations under the deferred payment agreement to that other authority.
Any period during which a local authority was meeting the needs in question under section 19 or 20(6) is to be disregarded for the purposes of this section.