stalbe
it depends on how you measure the loop AC response
the way u use is assume the feedback is negative feedback, neglect the "-" minus polarity.
the way the author used is just simulate the loop gain and phase, include the "-" minus polarity, so, you should observe the phase margin when phase=0deg instead of 180deg;