Not everything that a personage of the Bible says, is revelation, it is necessary to discern
The prophet Nathan told David something that was not a revelation, but a personal opinion
It is necessary to take heed that not everything a personage in the Bible says should be taken as a revelation or divine teaching. It is necessary to apply common sense and above all, see if what that Biblical personage says at that moment is in concordance with the rest of the Bible.
Not everything that the actual prophets say (if indeed there are) has to be the word of God. Not even everything the true prophets of ancient times said or advised was a divine message, as is seen in the case of Nathan.
3, we see that Nathan advised
David to follow the impulse of his heart and dedicate himself to construct
1 And it came to pass, when the king sat in his house, and the LORD had given him rest round about from all his enemies; 2 that the king said unto Nathan the prophet: See now, I dwell in an house of cedar, but the ark of God dwelleth within curtains. 3 And Nathan said to the king: Go, do all that is in thine heart; for the LORD is with thee. (II Samuel 7:1-3)
12 And when thy days be fulfilled, and thou shalt sleep with thy fathers, I will set up thy seed after thee, which shall proceed out of thy bowels, and I will establish his kingdom. 13 He shall build an house for my name, and I will establish the throne of his kingdom for ever. (II Samuel 7:12-13)
This warning is even clearer in I Chronicles 17:1-4, where we see that in verse 2, Nathan tells David to do everything that is in his heart because God is with him, however, two verses later God tells Nathan the opposite, ordering him to tell David that he was not going to build the Temple. This is reaffirmed in I Chronicles 22:7-10.
1 Now it came to pass, as David sat in his house, that David said to Nathan the prophet: Lo, I dwell in an house of cedars, but the ark of the covenant of the LORD remaineth under curtains. 2 Then Nathan said unto David: Do all that is in thine heart; for God is with thee. 3 And it came to pass the same night, that the word of God came to Nathan, saying: 4 Go and tell David my servant, Thus saith the LORD: Thou shalt not build me an house to dwell in. (I Chronicles 17:1-4)
As we can see, what at first glance anyone would have taken as having come from God, because a prophet was saying it, was not a word nor advice from God, but the words and advice of a prophet that although he was a good man and under the influence of the Holy Spirit, his words should not be taken as coming from Heaven. When he advised David to follow the impulses of his heart, he was wrong. If that was so with prophets like Nathan, who evidently was a true prophet, how can we possibly believe with our eyes closed that everything that a pastor or someone who calls himself inspired says, has to be the word of God. No matter how sincere he may be, he could be sincerely mistaken. We have to know how to discern.