Closured pubid logic. Removed UUID until DB is used (then will reconsider PKEY options)
URLquery is now always an array. Updated target logic to support this.