Note: The text has been updated per official errata. [Source]
Even a broken object remembers what it means to be a functioning whole. You restore a broken object or damaged construct to a functional state, as if it were new and intact. Any pieces missing from the object or construct remain missing. Significant missing pieces may prevent proper functioning. If the object uses charges, the object becomes fully charged. A timeworn object becomes fully charged, but doesn’t lose the timeworn condition (this spell is one of the few ways a timeworn item can be recharged). For 1 hour after this spell is cast on a timeworn object, that object does not suffer any chance of glitching. Other consumables such as ammunition are not restored.
When this spell is cast upon a damaged construct, all hit point damage dealt to that construct is healed. When this spell is cast upon a destroyed construct, it is restored to full functionality and full hit points, provided no significant portion of the destroyed construct (such as an entire limb) is missing. Constructs brought back in this fashion regain their memories up to the moment of their destruction and have no particular inclination to serve the caster.
If you attempt to cast this spell on an object or a construct that has been destroyed for more than 10 years per caster level you possess, the spell fails.
Pathfinder Campaign Setting: Technology Guide © 2014, Paizo Inc.; Authors: James Jacobs and Russ Taylor.