Plaintiff-appellants Kenneth Wayne Harter and John Robert Payne (collectively “plaintiffs”) appeal the trial court’s grant of defendant-appellees’ C. D. Vernon and U.S. Fidelity and Guaranty Company (collectively “defendants”) motion for summary judgment under N.C.R. Civ. P. 56. Although the trial court delineated its grant of that motion only by stating that “the motion should be granted for the reasons stated in defendants’ brief,” we agree with defendants that plaintiffs failed to timely file their action in state court, and thus the statute of limitations has run on plaintiffs’ claims. Therefore, we hold that summary judgment for defendants was proper.
Due to our disposition of this case, we need relate very little of the factual history. Plaintiffs Harter and Payne worked as a dispatcher and a patrol deputy (respectively) for the Rockingham County Sheriff’s Department under defendant Sheriff C. D. Vernon (“Sheriff Vernon”). In 1994 Sheriff Vernon was up for re-election in the democratic primary campaign and was (himself and through other employees) actively soliciting and recruiting support throughout the sheriff’s department. Several members of the sheriff’s department, including plaintiffs, did not actively participate in any campaign nor outwardly exhibit which candidate they were supporting. Nonetheless, Sheriff Vernon won the election and immediately thereafter, began an investigation of employees who “had not been loyal to him.” On 15 July 1994, two months after the primary election, Sheriff Vernon fired seven of his employees including plaintiffs. Other officers within the department made statements that Sheriff “Vernon was firing the people on ‘the list.’ ” Although both plaintiffs had recent performance appraisals, neither appraisals gave notice that either plaintiff was performing unsatisfactorily or was in danger of losing his job.
As to the procedural history, we take it directly from plaintiffs’ brief to this Court. Originally, plaintiffs filed suit in federal district court on 31 January 1995 asserting claims under 42 U.S.C. § 1983 for *88violation of their federal First Amendment and Due Process rights, wrongful discharge in violation of public policy, and violation of the North Carolina Constitution. On 22 March 1996, the United States District Court denied defendants’ motion for summary judgment concluding that genuine issues of material fact existed regarding Sheriff Vernon’s motive for firing plaintiffs and rejecting defendants’ Eleventh Amendment immunity defense. In Harter v. Vernon, 953 F. Supp. 685 (M.D.N.C. 1996), defendants made an interlocutory appeal of the Eleventh Amendment decision; however, the United States Fourth Circuit Court of Appeals affirmed. Nevertheless, on remand the United States District Court concluded that the intervening Fourth Circuit decision in Jenkins v. Medford, 119 F.3d 1156 (4th Cir. 1996), cert. denied, 522 U.S. 1090, 139 L. Ed. 2d 869 (1998) required dismissal of plaintiffs’ 42 U.S.C. § 1983 claims. See Harter v. Vernon, 980 F. Supp. 162, 165 (M.D.N.C. 1997). The federal court declined to retain the supplemental jurisdiction it had obtained over plaintiffs’ state constitutional and wrongful discharge claims. Thus on 5 November 1997, the court dismissed plaintiffs’ state claims without prejudice. Plaintiffs initially appealed to the Fourth Circuit Court the federal court’s involuntary dismissal of their state claims. However, on 23 February 1998, the parties stipulated to a dismissal of that appeal and the Fourth Circuit dismissed pursuant to the parties’ stipulation on 24 February 1998. Consequently on 20 July 1998, plaintiffs filed this action in state court alleging that they had been wrongfully discharged by defendants and that defendants had violated their right to freedom of speech and to participate freely in the political process under the Constitution of North Carolina.
In their answer, defendants alleged eight affirmative defenses, including the statute of limitations. On 11 March 1999, defendants filed a motion for summary judgment in which they did not specifically state the statute of limitations as grounds. However, on 6 April 1999, the trial court allowed defendant’s motion “for the reasons stated in defendants’ brief.” Plaintiffs now appeal to this Court the trial court’s grant of summary judgment to the defendants for several reasons. However, because we agree with defendants that plaintiffs’ state action was untimely filed, we do not reach plaintiffs’ arguments.
Recently this Court visited this very issue that is now before us: whether, after plaintiffs have filed their action in federal court and had their state claims dismissed without prejudice, plaintiffs can then filé their actions in state court after the statute of limitations has run *89on the original claim. In the alternative, the question becomes does the federal action toll the statute of limitations or do plaintiffs automatically gain the advantage of N.C.R. Civ. P. 41(a) which allows plaintiffs one year from their voluntary dismissal in which to file.
 We begin by noting that although plaintiffs argue they took a voluntary dismissal in federal court (thus N.C.R. Civ. P. 41(a) should apply giving plaintiffs one year to refile in state court), plaintiffs unambiguously admit that the federal district court “dismissed the [state claims] without prejudice” first. Such a dismissal, if under North Carolina law, would be an involuntary dismissal pursuant to N.C.R. Civ. P. 41(b) instead of 41(a), this Court having held that:
“[I]f the [federal] court specifies that the dismissal of an action ... is without prejudice, it may also specify in its order that a new action based on the same claim may be commenced within one year or less after such dismissal.” [Thus,] [i]f plaintiff was to take advantage of the savings provision, it was his responsibility to convince the federal courts to include in the order or opinion a statement specifying that plaintiff had an additional year to refile. . . .
Clark v. Velsicol Chemical Corp., 110 N.C. App. 803, 809, 431 S.E.2d 227, 230 (1993) (emphasis added) (quoting N.C.R. Civ. P. 41(b)). Thus, under the present circumstances and pursuant to well established case law, plaintiffs would not be entitled to the additional year to refile provided in N.C. Gen. Stat. § 41(a) since the order did not so specify. Nevertheless, we choose to address plaintiffs’ argument from the standpoint that they, in fact, did take a voluntary dismissal of their state claims in federal court.
The plaintiff in Huang v. Ziko, 132 N.C. App. 358, 511 S.E.2d 305 (1999), like the present plaintiff, initially filed his complaint in federal court and then attempted to file in state court after the federal court dismissed his action without prejudice. In his attempt to convince this Court that the trial court had erred in dismissing his action, that plaintiff argued:
nce the federal action was no longer pending, the time for filing his complaint in state court should have been extended for the portion of the three-year limitations period that had not been used when he filed the federal action. Since less than a year and a half had passed when plaintiff filed his federal action, he would *90have had more than a year and a half after 7 December 1995 to file his complaint in state court.
Id. at 361, 511 S.E.2d at 307-08. However, this Court found the plaintiff’s contention unpersuasive, opining:
The rule which plaintiff would have this Court adopt is contrary to the policy in favor of prompt prosecution of legal claims. Furthermore, such a rule is contrary to the general rule that “[i]n the absence of statute, a party cannot deduct from the period of the statute of limitations applicable to his case the time consumed by the pendency of an action in which he sought to have the matter adjudicated, but which was dismissed without prejudice as to him[.]” 51 Am. Jur. 2d Limitation of Actions § 311 (1970). In this case, no statute or rule provides for the exclusion of the time during which the federal action was pending from the limitations period.
We believe the question presented by this appeal is controlled by 28 U.S.C.A. § 1367 (1993). That federal statute provides that when a federal district court has original jurisdiction over a civil action it may also exercise “pendent” or "supplemental jurisdiction over all other claims that are so related to claims in the action within such original jurisdiction that they form part of the same case or controversy[.]” 28 U.S.C.A. § 1367(a). A federal district court may decline to exercise supplemental jurisdiction over a claim if it “has dismissed all claims over which it has original jurisdiction[.]” 28 U.S.C.A. § 1367(c)(3). The statute further provides that the period of limitations for any supplemental claim “shall be tolled while the claim is pending and for a period of 30 days after it is dismissed unless State law provides for a longer tolling period.” 28 U.S.C.A. § 1367(d). Since the claims now asserted by plaintiff were supplemental claims dismissed by the United States District Court, he was entitled to thirty additional days to file his complaint in state court after the United States Court of Appeals reached its decision, unless some state statute provided for a longer period of time.
Because North Carolina has no applicable “grace period” longer than the thirty-day period set out in 28 U.S.C.A. § 1367, the statute of limitations was tolled while the federal action was pending and for thirty days thereafter. Plaintiff could have filed *91his complaint in state court at any time during the pendency of the federal action and up to thirty days after the United States Court of Appeals reached its decision ....
Id. at 361-62, 511 S.E.2d 308 (emphasis added) (citations omitted).
In the case at bar, there is no dispute that the statute of limitations began to run when plaintiffs were terminated on 15 July 1994 and ordinarily would expire on 15 July 1997. Like the plaintiff in Huang, supra, the plaintiffs at bar first filed in federal court on 31 January 1995 (6 months after the limitations period had begun to run), and the federal district court dismissed without prejudice plaintiffs’ state claims on 5 November 1997. Plaintiffs appealed to the United States Fourth Circuit Court which later dismissed plaintiffs’ appeal on 24 February 1998 pursuant to the parties’ stipulated voluntary dismissal. Subsequently on 20 July 1998, plaintiffs filed their state claims action in state court. We find the facts in Huang sufficiently analogous and hold that plaintiffs had thirty days from 24 February 1998 to refile their state claims in state court, not one year.
Under [28 U.S.C. § 1367(d)], the state period of limitations for . a plaintiff’s pendent state claims is tolled for a period of thirty days after the federal district court has dismissed the plaintiff’s claims. ... If, however, a plaintiff appeals the federal district court’s dismissal of his claims, the plaintiff’s pendent state claims are tolled for a period of thirty days following the date of the decision of the federal court of appeals.
Estate of Fennell v. Stephenson, 137 N.C. App. 430, 435, 528 S.E.2d 911, 914 (2000).
However, plaintiffs argue that because Huang, supra, was decided seven months after the instant action was filed in state court, Huang cannot be applied retroactively. We recognize that plaintiffs’ argument is essentially that Huang created an ex post facto effect with regard to whether the statute of limitations is tolled by the federal action and how much time a plaintiff, under the present circumstances, has to refile her complaint in state court after the federal court has dismissed it. Plaintiff’s argument is meritless.
Under U.S. Const, art. I, § 10, cl. 1, and N.C. Const, art. I, § 16, the law is rwell established that there are two critical elements which must be present for a law to be considered “ex post facto”: (1) the case law or statute must apply to events occurring before its enactment, and (2) the case law or .statute as applied must disadvantage *92the offender affected by it. See State v. Jones, 133 N.C. App. 448, 516 S.E.2d 405 (1999), and In Re Hayes, 111 N.C. App. 384, 432 S.E.2d 862 (1993). Thus, in order for plaintiffs’ objection to be sustained, this Court must find that Huang was both decided after plaintiffs’ firing and that applying Huang to plaintiffs’ case will disadvantage them.
First, we agree with plaintiffs that Huang was decided after plaintiffs filed their action. However, we find it unnecessary to rely solely on Huang since earlier cases bring us to the same conclusion. The key to whether a plaintiff in the present situation gains the additional year provided under N.C.R. Civ. P. 41(a) is governed by how the federal court gained jurisdiction over the state issues.
Ordinarily, a voluntary dismissal in federal court under Federal Rule 41 “leaves the situation as if the action had never been filed.” Wright & Miller, Federal Practice and Procedure-. Civil § 2367 (1971). “The statute of limitations is not tolled by bringing an action that is later voluntarily dismissed.” Id. Federal courts ordinarily need not consider the applicability of a savings provision, as the federal rule contains no such provision. This applies to cases in federal court in which jurisdiction is not based on diversity of citizenship and in which there is no occasion for the federal court to apply state substantive law.
For example, in Humphreys v. United States, 272 F.2d 411 (9th Cir. 1959), a plaintiff sued the United States government under the Federal Tort Claims Act. Plaintiff’s first suit in federal court was brought within the statute of limitations, but plaintiff voluntarily dismissed in order to sue in another federal court more convenient to the parties and witnesses. Plaintiff refiled in the other federal court outside the statute. The court upheld the denial of plaintiff’s motion to set aside the order of dismissal and reinstate her first suit. It noted that the statute had expired when the motion was made because plaintiff’s dismissal under the federal rules did not toll the statute and left “the situation the same as if the suit had never been brought in the first place.” Id. at 412. Similar treatment of federal voluntary dismissals in noniversity cases is seen in patent claims — see A.B. Dick Co. v. Marr, 197 F.2d 498 (2d Cir. 1952), cert. denied, 344 U.S. 878, 97 L. Ed. 680, reh’g denied, 344 U.S. 905, 97 L. Ed. 699 (1952) — and cases involving § 1983 claims [with state claims attached], see Cabrera v. Municipality of Bayamon, 622 F.2d 4 (1st Cir. 1980). *93 Thus, a voluntary dismissal under the Federal Rules in a non-diversity case in federal court does not toll the statute of limitations or invoke a savings provision.
Bockweg v. Anderson, 328 N.C. 436, 438-39, 402 S.E.2d 627, 628-29 (1991) (emphasis added). Furthermore,'
In Haislip v. Riggs, 534 F. Supp. 95 (W.D.N.C. 1981), plaintifffiled in federal court a medical malpractice claim [a state claim] which was voluntarily dismissed, by stipulation of the parties, without prejudice. Plaintiff sought to file the same action in a North Carolina state court within a year of the dismissal, but outside the statute of limitations, and suffered summary judgment on statute of limitations grounds because High v. Broadnax precluded application of the savings provision where the original suit was brought in a federal court.... Plaintiff then sought to refile his suit in federal court, whereupon defendant again moved to dismiss. The court in Haislip stated:
“This Court is of the opinion North Carolina Rule 41(a) is a tolling provision legislatively adopted and falls within the first category of the analysis [requiring application of state substantive law].... The tolling of a state statute of limitations in a diversity case is strictly a substantive matter of state law which Erie Railroad Co. v. Tompkins, 304 U.S. 64, 58 S. Ct. 817, 82 L. Ed. 1188 (1938) and Guaranty Trust Co. v. York, 326 U.S. 99, 65 S. Ct. 1464, 89 L. Ed. 2079 (1945) command that this Court follow absent substantial countervailing federal interests. Id. ...”
[Haislip, 435 F. Supp.] at 98 (emphasis added) (citation omitted).. ..
The effect of a voluntary dismissal in federal court, pursuant to the Federal Rules, thus depends on whether the federal court’s jurisdiction is based on the existence of a federal question or on diversity of citizenship. ... [T]he effect of a voluntary dismissal taken under the Federal Rules by a plaintiff in a federal court sitting in diversity applying North Carolina law is to allow the plaintiff up to one year to refile in federal court.
Id. at 440-41, 402 S.E.2d at 630 (emphasis added). Therefore, it is apparent that where the federal court gains jurisdiction over state issues strictly because the action is a diversity action (which is not *94the case here), the federal court must apply state substantive law in all respects of the case, including in its dismissal of the claims with or without prejudice. However where, as in the case at bar, the federal court gains jurisdiction over state claims supplementally, pursuant to 28 U.S.C.A. § 1367(a), because the action was first brought based on federal or constitutional law, the court is not bound to state substantive law only. Thus because, in the case before us, the federal court gained supplemental jurisdiction over plaintiffs’ state law claims not due to diversity, 28 U.S.C.A. § 1367(d) applies and the limitations period for plaintiffs’ supplemental claims was tolled for 30 days after the action was dismissed because “a voluntary dismissal under the Federal Rules in a nondiversity case in federal court does not toll the statute of limitations or invoke a savings provision.” Bockweg, 328 N.C. at 439, 402 S.E.2d at 629. “The United States Code provides that when a state claim is brought in federal district court pursuant to 28 U.S.C. § 1367(a), the state period of limitations for the claim ‘shall be tolled while the claim is pending and for a period of 30 days after it is dismissed unless State law provides for a longer tolling period.’ ” Fennell, 137 N.C. App. at 435, 538 S.E.2d at 914 (quoting 28 U.S.C. § 1367(d) (1994)). In the case at bar, with plaintiffs’ dismissal not falling under N.C.R. Civ. P. 41(a), there is no state law available to them that tolls the limitations period.
 Plaintiffs further contend that “[defendants’ statute of limitations defense is not properly before the court” because defendants did not “specify in its motion an intent to argue the statue of limitations . . . .” Again, we are unpersuaded. Although plaintiffs cite Miller v. Talton, 112 N.C. App. 484, 435 S.E.2d 793 (1993) in support of their position, we find it inapposite to their position and, in fact, find it dis-positive in defendants’ favor.
In Miller, the plaintiffs argued that because the defendants failed to formally amend their answer to affirmatively plead the statute of limitations, defendants’ failure constituted a waiver of that defense. Id. at 487, 435 S.E.2d at 796. Finding that plaintiffs had either expressly or impliedly consented to defendants’ raising the defense, this Court stated:
The affirmative defense relied upon should be referred to in the motion for summary judgment; however, in the absence of an expressed reference, if the affirmative defense was clearly before the trial court, the failure to expressly mention the defense in the motion will not bar the trial court from granting *95 the motion on that ground. This is especially true where the party opposing the motion has not been surprised and has had full opportunity to argue and present evidence. “Thus, although it is better practice to require a formal amendment to the pleadings, unpleaded defenses, when raised by the evidence, should be considered in resolving a motion for summary judgment.” Ridings v. Ridings, 55 N.C. App. 630, 632, 286 S.E.2d 614, 615-16, disc. review denied, 305 N.C. 586, 292 S.E.2d 571 (1982).
Id. at 487, 435 S.E.2d at 796-97 (citations omitted).
In the case at bar, we find it disingenuous for plaintiffs to argue that they did not have proper notice of defendants’ intent to plead the statute of limitations as a defense. From the very beginning, defendants pled the affirmative defense in their answer. Thus no other notice was necessary. Additionally, plaintiffs’ argument that because defendants failed to allege the defense in their motion for summary judgment they waived the defense is clearly incorrect under Miller, supra.
 Finally, plaintiffs argue that because the trial court granted defendants’ summary judgment motion “ ‘for the reasons stated in defendants’ brief,’ ” defendants cannot now argue the statute of limitations defense because it could not have been the basis upon which the trial court granted summary judgment since it was not mentioned in defendants’ brief to that court. Again, we are unpersuaded by plaintiffs’ argument.
It has long been the law in North Carolina that in granting or denying a motion for summary judgment under N.C. Gen. Stat. § 1A-1, Rule 56, the trial court may consider “the pleadings, depositions, interrogatories, and admissions on file, together with any affidavits ...” which are before the court. Johnson v. Insurance Co., 300 N.C. 247, 252, 266 S.E.2d 610, 615 (1980). Therefore, it was proper in this case for the trial court to consider defendants’ answer (which included their affirmative defense of the statute of limitations) in granting their motion for summary judgment. Furthermore, our Supreme Court has long established that:
If the granting of summary judgment can be sustained on any grounds, it should be affirmed on appeal. If the correct result has been reached, the judgment will not be disturbed even though the trial court may not have assigned the correct reason for the judgment entered. . . .
*96 Shore v. Brown, 324 N.C. 427, 428, 378 S.E.2d 778, 779 (1989) (emphasis added).
Therefore, the judgment of the trial court is
Judges GREENE and HORTON concur.