#include <bits/stdc++.h>
using namespace std;
map<pair<int, int>, bool> mp;
int m, n;
int a[100006];
int main() {
  cin >> n >> m;
  int x, y;
  for (int i = 1; i <= m; i++) {
    cin >> x >> y;
    mp[make_pair(x, y)] = 1;
    mp[make_pair(y, x)] = 1;
  }
  for (int i = 1; i <= n; i++) {
    mp[make_pair(i, i)] = 1;
  }
  for (int i = 1; i <= n; i++) {
    a[i] = i;
  }
  int cnt2 = 3000000 / m;
  while (cnt2--) {
    random_shuffle(a + 1, a + n + 1);
    a[0] = a[n];
    int cnt = 0;
    for (int i = 0; i < n; i++) {
      if (!mp[make_pair(a[i], a[i + 1])]) {
        cnt++;
      }
    }
    if (cnt < m) continue;
    for (int i = 0; m; i++) {
      if (!mp[make_pair(a[i], a[i + 1])]) {
        printf("%d %d\n", a[i + 1], a[i]);
        m--;
      }
    }
    return 0;
  }
  puts("-1");
  return 0;
}
