YHWH, or God, or God the Father (or the entire trinity) ALONE knows the hearts of the children of men according to 1 King. 8:39, but the very same attributes are mentioned in relation to Jesus Christ in Rev. 2:23. So is it a lie that God ALONE possesses such incredible knowledge? The only way to solve this and avoid making God a liar, is to accept that Jesus is God and the trinity is valid. Or else God is NOT alone knowing the hearts of the children of men, as he claims he is.
This is about God in the old testament
1 King 8:39 Then hear thou in heaven thy dwelling place, and forgive, and do, and give to every man according to his ways, whose heart thou knowest; (for thou, even THOU ONLY, KNOWEST THE HEARTS OF ALL THE CHILDREN OF MEN;)
Jer. 11:20 But, O Lord of hosts, that judgest righteously, that triest the reins and the heart, let me see thy vengeance on them: for unto thee have I revealed my cause.
Jer. 20:12 But, O Lord of hosts, that triest the righteous, and seest the reins and the heart, let me see thy vengeance on them: for unto thee have I opened my cause.
Ps. 7:9 Oh let the wickedness of the wicked come to an end; but establish the just: for the righteous God trieth the hearts and reins.
Ps. 26:2 Examine me, O Lord, and prove me; try my reins and my heart.
Pro. 24:12 If thou sayest, Behold, we knew it not; doth not he that pondereth the heart consider it? and he that keepeth thy soul, doth not he know it? and shall not he render to every man according to his works?
1 Chronicles 28:9 And thou, Solomon my son, know thou the God of thy father, and serve him with a perfect heart and with a willing mind: for the Lord searcheth all hearts, and understandeth all the imaginations of the thoughts: if thou seek him, he will be found of thee; but if thou forsake him, he will cast thee off for ever.
Jer. 17:10 I THE LORD SEARCH THE HEART, I TRY THE REINS, even to give every man according to his ways, and according to the fruit of his doings.
This is about Jesus in the new testament
Notice that Rev. 2:23 contains almost the exact same phrase and wordings as Jer. 17:10. Is God the author of confusion, or does he maybe wants us to understand that Jesus is God, and that he shares the same trinity as God the Father?
Rev. 2:18 And unto the angel of the church in Thyatira write; These things saith THE SON OF GOD, who hath his eyes like unto a flame of fire, and his feet are like fine brass;23 And I will kill her children with death; and all the churches shall know that I AM HE (ego eimi) WHICH SEARCHETH THE REINS AND HEARTS: and I will give unto every one of you according to your works.
The Spirit makes intercession for us, and we can read about “he that searcheth the hearts knoweth what is the mind of the Spirit”. Who is this referred to? Could it be Jesus, since we know that he too makes intercessions for us before God (God the Father)? We can read that the REASON why he searches the hearts of the saints, is due to the plan to make an intercession for them, and it’s not possible to make an intercession before God (God the Father) for someone unless you know what’s in this person’s heart and can see his true motives.
Rom. 8:26 Likewise the Spirit also helpeth our infirmities: for we know not what we should pray for as we ought: but the Spirit itself maketh intercession for us with groanings which cannot be uttered.27 And he that searcheth the hearts knoweth what is the mind of the Spirit, because he maketh intercession for the saints according to the will of God.
Hebr. 7:22 By so much was Jesus made a surety of a better testament.—24 But this man, because he continueth ever, hath an unchangeable priesthood.25 Wherefore he is able also to save them to the uttermost that come unto God by him, seeing he ever liveth to make intercession for them.26 For such an high priest became us, who is holy, harmless, undefiled, separate from sinners, and made higher than the heavens
So we can see that God the Father, Jesus the son, and the holy Spirit, are linked together in the same unity – even if they are not one and the same.